home *** CD-ROM | disk | FTP | other *** search
/ JCSM Shareware Collection 1993 November / JCSM Shareware Collection - 1993-11.iso / cl720 / sst115j.lzh / SST.TXT < prev    next >
Text File  |  1992-10-09  |  121KB  |  3,438 lines

  1.  
  2.                                   SST  1.15
  3.                                   ---------
  4.  
  5.                   Stevens Software Tools (Turbo)  'C' library
  6.                   -------------------------------------------
  7.  
  8.     
  9.  
  10.  
  11.                                    CONTENTS
  12.  
  13.  
  14.     1.      Introduction . . . . . . . . . . . . . . . . . . . . . . . . .
  15.       1.1        Copyright . . . . . . . . . . . . . . . . . . . . . . . .
  16.       1.1.1           Legal notice . . . . . . . . . . . . . . . . . . . .
  17.       1.2        Technical support . . . . . . . . . . . . . . . . . . . .
  18.       1.3        Distribution  . . . . . . . . . . . . . . . . . . . . . .
  19.         1.3.1         P.D.N . . . . . . . . . .  . . . . . . . . . . . . .
  20.         1.3.2         H.P.N . . . . . . . . . .  . . . . . . . . . . . . .
  21.         1.3.3         NON COMMERCIAL use . . . . . . . . . . . . . . . . .
  22.         1.3.4         COMMERCIAL use . . . . . . . . . . . . . . . . . . .
  23.       1.4        Acknowledgements  . . . . . . . . . . . . . . . . . . . .
  24.  
  25.  
  26.     2.      Features . . . . . . . . . . . . . . . . . . . . . . . . . . .
  27.       2.1        Low level functions . . . . . . . . . . . . . . . . . . .
  28.       2.2        Window System . . . . . . . . . . . . . . . . . . . . . .
  29.       2.3        Data Entry System . . . . . . . . . . . . . . . . . . . .
  30.       2.4        Editor  . . . . . . . . . . . . . . . . . . . . . . . . .
  31.  
  32.     3.      Using SST  . . . . . . . . . . . . . . . . . . . . . . . . . .
  33.       3.1        Using the library functions . . . . . . . . . . . . . . .
  34.         3.1.1         Compiling and Linking  . . . . . . . . . . . . . . .
  35.         3.1.1         Using the MAKEFILE . . . . . . . . . . . . . . . . .
  36.  
  37.     4.      Low level functions  . . . . . . . . . . . . . . . . . . . . .
  38.       4.1        Video functions . . . . . . . . . . . . . . . . . . . . .
  39.       4.2        Keyboard functions  . . . . . . . . . . . . . . . . . . .
  40.       4.3        Mouse functions . . . . . . . . . . . . . . . . . . . . .
  41.       4.4        String functions  . . . . . . . . . . . . . . . . . . . .
  42.       4.5        Miscellaneous functions . . . . . . . . . . . . . . . . .
  43.       4.6        Fossil functions  . . . . . . . . . . . . . . . . . . . .
  44.  
  45.     5.      High level functions . . . . . . . . . . . . . . . . . . . . .
  46.       5.1        Window functions  . . . . . . . . . . . . . . . . . . . .
  47.       5.2        Menu functions  . . . . . . . . . . . . . . . . . . . . .
  48.       5.3        Data entry functions  . . . . . . . . . . . . . . . . . .
  49.       5.4        Editor functions  . . . . . . . . . . . . . . . . . . . .
  50.       5.5        Help system functions . . . . . . . . . . . . . . . . . .
  51.       5.6        Selection system functions  . . . . . . . . . . . . . . .
  52.  
  53.  
  54.  
  55.  
  56.     1.  Introduction:
  57.     -----------------
  58.  
  59.  
  60.         This SST toolkit is provided to extend your C compilers standard
  61.         run time library. It contains a substantial number of functions
  62.         which provide a variety of capabilities.
  63.  
  64.         The toolkit may be used FREE of charge (i.e. dont send any money
  65.         to me) for NON-COMMERCIAL use.  The fee for COMMERCIAL use has not
  66.         been established yet but you may contact me regarding this for
  67.         more information.
  68.  
  69.         The only compiler support for the moment is Turbo C, Turbo C++ and
  70.         Borland C++ (however no C++ extensions have been used here).
  71.  
  72.  
  73.         The toolkit has the following features.
  74.  
  75.  
  76.         o       Low Level video support.
  77.         o       Low Level keyboard support.
  78.         o       Low level mouse support.
  79.         o       Low level string manipulation
  80.         o       Low level fossil interface
  81.  
  82.         o       High level windows system.
  83.         o       High level pull down menus.
  84.         o       High level formatted data entry.
  85.         o       High level help interface.
  86.         o       High level editor interface.
  87.         o       High level pick and select interface.
  88.  
  89.  
  90.         I would expect several small bugs to be floating around, so if you
  91.         find any then please let me know, or better still try to fix them
  92.         and tell me what to do.
  93.  
  94.  
  95.         Thank you to Borland International for your fine range of
  96.         Compiler products.
  97.  
  98.  
  99.  
  100.  
  101.     1.1  Copyright:
  102.     ---------------
  103.  
  104.         Documentation - (C)  Copyright  1991,1992  by Steven Lutrov.
  105.  
  106.         Source code   - (C)  Copyright  1991,1992  by Steven Lutrov.
  107.  
  108.  
  109.         No patent liability is assumed with respect to the use of the
  110.         information contained herein.
  111.  
  112.         You may develop any program you want by using the SST library.
  113.  
  114.         You may sell or give away your programs you develop using the
  115.         toolkit including executable programs and their object modules.
  116.  
  117.         You may modify this code code to your hearts content for your
  118.         own use.
  119.  
  120.         You may not publish this source code as your own work even if you
  121.         have modified it.
  122.  
  123.  
  124.  
  125.  
  126.  
  127.     1.1.1  Legal notice:
  128.     --------------------
  129.  
  130.         In no event shall Steven Lutrov or be liable to you or anyone else
  131.         for any damages or costs, including, but not limited to, any lost
  132.         profits, lost savings, lost income, lost information, loss of life,
  133.         loss of spouses life, or any other incidental or consequential damages
  134.         arising out of  the use or inability to use the SST library.
  135.  
  136.  
  137.  
  138.  
  139.  
  140.     1.2  Technical support:
  141.     ----------------------
  142.  
  143.  
  144.         Since I run a BBS system I am prepared to setup an Echomail
  145.         support conference and any messages can be posted here where
  146.         I or other users will try and answer any qeuries etc..
  147.  
  148.         Should you have any improvements additions or corrections to the
  149.         source code, then by all means post them to me, they are extremely
  150.         welcome here.
  151.  
  152.         Your name ( if you have no objections) will then added to the
  153.         acknowledgements section.
  154.  
  155.  
  156.         o       Land mail               Steven Lutrov
  157.                                         P.O. Box 466
  158.                                         Essendon 3040, VIC
  159.                                         Australia
  160.  
  161.         o       Electronic mail         The Software Parlour BBS
  162.                                         phone  - 61-3-338-3794
  163.                                         bauds  - V42bis,V32,V22bis,V22,V21
  164.  
  165.                                         Crash Mail - 24 hours
  166.  
  167.                                         Email  - 3:635/544@fidonet
  168.                                                  3:635/534@fidonet
  169.                                                  58:4100/34@intlnet
  170.                                                  58:4100/40@intlnet
  171.  
  172.  
  173.      1.3.  Distribution:
  174.      -------------------
  175.  
  176.  
  177.      You are encouraged to  copy the toolkit files and  share  it  freely
  178.      with others.  You have the luxury of trying out the complete programs
  179.      at your own pace and in the comfort of  your  own home  or workplace.
  180.  
  181.  
  182.  
  183.      1.3.1.  P.D.N:
  184.      --------------
  185.  
  186.  
  187.      The  PDN  ( Programmers Distribution Network ) is   dedicated   to
  188.      supporting programmers all  over the  world  and has  many notable
  189.      programmers involved. The PDN distributes  source code, utilities,
  190.      libraries .., shareware, public domain and freeware etc.
  191.  
  192.  
  193.      This toolkit is also officially released to the PDN and shall meet
  194.      all the requirements required by the PDN.
  195.  
  196.  
  197.      More information may be obtained from the following..
  198.  
  199.  
  200.      PDN International Coordinator    - Erik Vanriper
  201.                                         1:260/230@fido.org
  202.  
  203.  
  204.  
  205.      1.3.2.  H.P.N:
  206.      --------------
  207.  
  208.  
  209.      The  HPN (Hax & Programming Network) is dedicated to supporting
  210.      programmers all over Australia with  many notable programmers
  211.      involved. The HPN distributes  source code, utilities, libraries ..,
  212.      shareware, public domain and freeware etc.
  213.  
  214.  
  215.      This toolkit is also officially released to the HPN and shall meet
  216.      all the requirements required by the HPN.
  217.  
  218.      More information may be obtained abou HPN from the following..
  219.      You may also File request the file with a mailer using the
  220.      magic word "HPNINFO" form 3:635/544@fidonet or 58:4100/40@intlnet.
  221.  
  222.      OPN Coordinator                     - Steven Lutrov
  223.                                            3:635/534@fidonet
  224.                                            3:635/544@fidonet
  225.  
  226.  
  227.  
  228.  
  229.     1.3.3  NON-COMMERCIAL use:
  230.     --------------------------
  231.  
  232.         You may use the SST toolkit in a NON-COMMERCIAL enviroment free
  233.         of charge.
  234.  
  235.         Just for the sake of keeping track as to how many people might be
  236.         using this toolkit, I would appreciate if you send me a postcard
  237.         or leave a message on the BBS (if you are local).
  238.  
  239.  
  240.  
  241.  
  242.     1.3.4  COMMERCIAL use:
  243.     ----------------------
  244.  
  245.  
  246.         To use the SST toolkit in a COMMERCIAL enviroment, a commercial
  247.         license must be obtained, otherwise it would be a breach of
  248.         the copyright laws.
  249.  
  250.         For pricing information you will need to contact the author ,
  251.         see section 1.2 .
  252.  
  253.  
  254.  
  255.     1.4  Acknowledgements:
  256.     ----------------------
  257.  
  258.  
  259.         Steven Lutrov      - 91-08-12
  260.         ---------------------------
  261.               Iinitial release.
  262.  
  263.  
  264.         Richard Deguara    - 92-04-27
  265.         -----------------------------
  266.               Code modification to allow windows with no borders.
  267.  
  268.  
  269.  
  270.  
  271.     2.1  Low level functions
  272.     ------------------------
  273.  
  274.     The system was initially built with low level functions. All the
  275.     high level functions use the low level functions, such as reading
  276.     and writing to the screen. Initially the low level routines used
  277.     an assembler module to get full benefit from speed, but after
  278.     running a Profiler on the code the speed of the assembler code
  279.     was actually about 10% slower. I was naturally shocked being a
  280.     former assembler programmer.
  281.  
  282.     The low level video functions actually perform direct screen
  283.     writes and reads and rid the toolkit of any assembler code and
  284.     any tracking of video retrace registers. This is highly
  285.     questionable, non-portable and risky and very hacker-mentality
  286.     like, but I like it.
  287.  
  288.  
  289.  
  290.  
  291.  
  292.     2.2   Windows System:
  293.     --------------------
  294.  
  295.     The window library is set of text mode functions that display
  296.     smart windows that track the order of precedence. In other words
  297.     windows pop up on top of other ones, and can hide or dissappear
  298.     and make the window under it visible etc.
  299.     All the Data Entry, Editor, Menus, Help system use the the common
  300.     window library of functions.  All the windows created preserve
  301.     what they cover and hence restore the image beneath when the
  302.     window is closed. Each window can have borders titles footers
  303.     and selectable attributes.
  304.  
  305.     An important feature is that the windows do not have to be visible
  306.     in order to write to them. The title or border or any other
  307.     characteristic of a window may be altered while the window is
  308.     visible or invisible.
  309.  
  310.  
  311.  
  312.     2.3 Data Entry System:
  313.     ----------------------
  314.  
  315.     The data entry system uses the window library to implement general
  316.     purpose data entry. Here is how it works: You establsh a window
  317.     with the Westablish() function and build an array of data entry
  318.     field definitions. You write some prompting info to the window and
  319.     call the Fdataentry() function. The data entry function takes over
  320.     and collects the users key entries into a predefined buffer. There
  321.     are validation functions which can be used to check for correct
  322.     entry both prior to and after the entry is completed as well as
  323.     specifiying that the data entry must be of a certain type.
  324.     The types available include ASCII, Integer, Hexadecimal, Currency
  325.     etc etc. Each entry may also be converted to lower, upper or proper
  326.     case. A help function may be assigned to each field, the function
  327.     may be activated only once when you are on the field, always when
  328.     you are on the field, or only when you hit the help key on the
  329.     field.
  330.  
  331.     The fields use dynamically allocated linked lists for good memory
  332.     management.
  333.  
  334.  
  335.  
  336.     2.3   Editor:
  337.     -------------
  338.  
  339.  
  340.  
  341.         Editing keystrokes.
  342.         -------------------
  343.  
  344.  
  345.         RETURN       - inserts carrage return.
  346.         ESC          - exits the editor.
  347.         TAB          - moves to the next tab stop.
  348.         SHIFT_TAB    - moves to the previous tab stop.
  349.  
  350.         UP           - moves up one line.
  351.         PGUP         - moves up one page.
  352.         CTRL_PGUP    - moves to the top of the 1st page.
  353.  
  354.         DOWN         - moves down one line.
  355.         PGDN         - moves down one page.
  356.         CTRL_PGDN    - moves to the bottom of the last page.
  357.  
  358.         LEFT         - moves left on character.
  359.         CTRL_LEFT    - moves to the previous word.
  360.  
  361.         RIGHT        - move forward on character.
  362.         CTRL_RIGHT   - moves to the next word.
  363.  
  364.         HOME         - moves to the first column.
  365.         CTRL_HOME    - moves to the first column and row on
  366.                        the first page.
  367.  
  368.         END          - moves to the end of the last page.
  369.         CTRL_END     - moves to the last column and row on
  370.                        to the last page.
  371.  
  372.         INS          - toggles inserting mode.
  373.         DEL          - deletes the predecessing character.
  374.  
  375.         CTRL_Y       - deletes the current line.
  376.         CTRL_D       - deletes the predecessing word.
  377.  
  378.         F2           - Exits the editor.
  379.         F3           - erases the edit buffer.
  380.         F4           - reformats the current block.
  381.         ALT_F7       - copies the current block.
  382.         F7           - marks the block begining.
  383.         F8           - marks the block end.
  384.         ALT_F8       - move_block the current block;
  385.         F9           - deletes the current block.
  386.         F10          - unmark blocks.
  387.  
  388.  
  389.  
  390.  
  391.  
  392.     3.1  Using the library functions:
  393.     ---------------------------------
  394.  
  395.         Every function that is usable in the SST library has a
  396.         corresponding prototype in one of the associated header files.
  397.         As most of the high level functions are all windows based the
  398.         prototypes would usually be found in "sstwin.h".
  399.  
  400.  
  401.  
  402.     3.1.1  Compiling and Linking:
  403.     -----------------------------
  404.  
  405.         The basic command line compiler and linker commands to build
  406.         your files are as follows, provided you compiler paths are
  407.         all set up appropriately.
  408.  
  409.  
  410.         Using Turbo C++ or Turbo C
  411.         --------------------------
  412.  
  413.                   tcc demo.c ssts.lib
  414.  
  415.         Using Borland  C++
  416.         ------------------
  417.  
  418.                   bcc demo.c ssts.lib
  419.  
  420.  
  421.         I choose to use the IDE, so in here you will need to create a
  422.         project file for your application and include the SST library
  423.         in you project as well as you application file, then press
  424.         the Make key to make your application.
  425.  
  426.  
  427.  
  428.  
  429.     3.1.2  Using the Makefile:
  430.     --------------------------
  431.  
  432.         In the distribution archive there is a MAKEFILE provided. You
  433.         can build all the source code and the library as well as all
  434.         the demo programs by using the makefile.
  435.  
  436.  
  437.         On the commmand line simply enter "MAKE". The make utility is
  438.         provided with your compiler and will automatically try to find
  439.         and use a file called MAKEFILE unless another one is specified
  440.         as a parameter to MAKE.
  441.  
  442.         You should first check out the file MAKEFILE as you may need to
  443.         make changes here to match the path to your compiler. You can
  444.         also set a different memory model.
  445.  
  446.         The default memory model is SMALL.
  447.  
  448.  
  449.  
  450.  
  451.     4.  Low level functions:
  452.     ------------------------
  453.  
  454.         The low level functions are mainly for video, keyboard and mouse
  455.         functions.
  456.  
  457.         The high level functions make extensive use out of the lower
  458.         level functions
  459.  
  460.  
  461.  
  462.  
  463.     4.1  Video functions:
  464.     ---------------------
  465.  
  466.  
  467.  
  468.     ------------------------------------------------------------------------
  469.     NAME          ... vbeep
  470.  
  471.     DESCRIPTION   ... Make a mscbeep noise, what else !
  472.  
  473.     PROTOTYPE     ... void mscbeep            (int mode);
  474.  
  475.     ARGUMENTS     ... mode         - TRUE   - Will make an error beep.
  476.                                      FASLE  - Will make a pleasent beep;
  477.  
  478.     RETURNS       ... void
  479.  
  480.  
  481.     ------------------------------------------------------------------------
  482.     NAME          ... vblinkbit
  483.  
  484.     DESCRIPTION   ... Enables or disables the blink bit in the video
  485.                       register, this is only available on EGA and VGA
  486.                       systems.
  487.  
  488.     PROTOTYPE     ... void vblinkbit(int f);
  489.  
  490.     ARGUMENTS     ... f            - TRUE  blinking is enabled.
  491.                                      FALSE  intensity is enabled.
  492.  
  493.     RETURNS       ... void
  494.  
  495.  
  496.     ------------------------------------------------------------------------
  497.     NAME          ... vclearrline
  498.  
  499.     DESCRIPTION   ... Clears the an entire line on the screen with an
  500.                       attribute.
  501.  
  502.     PROTOTYPE     ... void vclearrline (unsigned char l, unsigned char a);
  503.  
  504.     ARGUMENTS     ... l            - The line to clear.
  505.                       a            - The attribute to clear the screen with.
  506.  
  507.     RETURNS       ... void
  508.  
  509.  
  510.  
  511.     ------------------------------------------------------------------------
  512.     NAME          ... vcls
  513.  
  514.     DESCRIPTION   ... Clears the entire screen with an attribte by scrolling.
  515.  
  516.     PROTOTYPE     ... void vcls (unsigned char a);
  517.  
  518.     ARGUMENTS     ... a            - The attribute to clear the screen with.
  519.  
  520.     RETURNS       ... void
  521.  
  522.  
  523.  
  524.  
  525.     ------------------------------------------------------------------------
  526.     NAME          ... vfill
  527.  
  528.     DESCRIPTION   ... Fills a rectangular area of the screen with a given
  529.                       char and attribute.
  530.  
  531.     PROTOTYPE     ... void vfill(int x, int y, int yy, int xx, int c, int a);
  532.  
  533.     ARGUMENTS     ... x            - Starting column.
  534.                       y            - Starting row.
  535.                       yy           - Number of rows.
  536.                       xx           - Number of columns.
  537.                       c            - Char used for filling
  538.                       a            - Attribute used for filling.
  539.  
  540.     RETURNS       ... void
  541.  
  542.  
  543.  
  544.     ------------------------------------------------------------------------
  545.     NAME          ... vget
  546.  
  547.     DESCRIPTION   ... Gets a character and attribute form the screen at the
  548.                       given coordinates.
  549.  
  550.     PROTOTYPE     ... int vget(int x, int y);
  551.  
  552.     ARGUMENTS     ... x            - Starting column.
  553.                       y            - Starting row.
  554.  
  555.     RETURNS       ... 16 bit word (integer) holding the char and attribute.
  556.                       The high order 8 bits hold the attribute and the low
  557.                       order 8 bits hold the char.
  558.  
  559.  
  560.     ------------------------------------------------------------------------
  561.     NAME          ... vgeta
  562.  
  563.     DESCRIPTION   ... Gets an attribute form the screen at the given
  564.                       coordinates.
  565.  
  566.     PROTOTYPE     ... int vgeta(int x, int y);
  567.  
  568.     ARGUMENTS     ... x            - Starting column.
  569.                       y            - Starting row.
  570.  
  571.     RETURNS       ... 16 bit word (integer) holding the attribute.
  572.  
  573.  
  574.  
  575.     ------------------------------------------------------------------------
  576.     NAME          ... vgetac
  577.  
  578.     DESCRIPTION   ... Gets an attribute form the screen at the current
  579.                       cursor coordinates.
  580.  
  581.     PROTOTYPE     ... int vgetac(void);
  582.  
  583.     ARGUMENTS     ... void
  584.  
  585.     RETURNS       ... 16 bit word (integer) holding the attribute.
  586.  
  587.  
  588.  
  589.  
  590.     ------------------------------------------------------------------------
  591.     NAME          ... vgetch
  592.  
  593.     DESCRIPTION   ... Gets a char form the screen at the given coordinates.
  594.  
  595.     PROTOTYPE     ... int vgetch(int x, int y);
  596.  
  597.     ARGUMENTS     ... x            - Starting column.
  598.                       y            - Starting row.
  599.  
  600.     RETURNS       ... 16 bit word (integer) holding the char.
  601.  
  602.  
  603.  
  604.     ------------------------------------------------------------------------
  605.     NAME          ... vgetchc
  606.  
  607.     DESCRIPTION   ... Gets a char form the screen at the current
  608.                       cursor coordinates.
  609.  
  610.     PROTOTYPE     ... int vgetchc(void);
  611.  
  612.     ARGUMENTS     ... void
  613.  
  614.     RETURNS       ... 16 bit word (integer) holding the char.
  615.  
  616.  
  617.  
  618.  
  619.     ------------------------------------------------------------------------
  620.     NAME          ... vgetcur
  621.  
  622.     DESCRIPTION   ... Returns the current cursor positions. Make sure you
  623.                       pass the address to the arguments.
  624.  
  625.     PROTOTYPE     ... void vgetcur(int *x, int *y);
  626.  
  627.     ARGUMENTS     ... x            - The column.
  628.                       y            - The row.
  629.  
  630.     RETURNS       ... void
  631.  
  632.  
  633.  
  634.     ------------------------------------------------------------------------
  635.     NAME          ... vhidecur
  636.  
  637.     DESCRIPTION   ... Hides the cursor making it invisible to the screen.
  638.  
  639.     PROTOTYPE     ... void vhidecur(void);
  640.  
  641.     ARGUMENTS     ... void
  642.  
  643.     RETURNS       ... void
  644.  
  645.  
  646.     ------------------------------------------------------------------------
  647.     NAME          ... visega
  648.  
  649.     DESCRIPTION   ... Test if an EGA adaptor is installed.
  650.  
  651.     PROTOTYPE     ... int visega(void);
  652.  
  653.     ARGUMENTS     ... void
  654.  
  655.     RETURNS       ... TRUE         - EGA adaptor present.
  656.                       FALSE        - EGA adaptor NOT present.
  657.  
  658.  
  659.     ------------------------------------------------------------------------
  660.     NAME          ... visvga
  661.  
  662.     DESCRIPTION   ... Test if an VGA adaptor is installed.
  663.  
  664.     PROTOTYPE     ... int visvga(void);
  665.  
  666.     ARGUMENTS     ... void
  667.  
  668.     RETURNS       ... TRUE        - VGA adaptor present.
  669.                       FALSE       - VGA adaptor NOT present.
  670.  
  671.  
  672.  
  673.     ------------------------------------------------------------------------
  674.     NAME          ... vnormalcur
  675.  
  676.     DESCRIPTION   ... Makes the cursor appear in its normal state, as it
  677.                       would from boot-up state.
  678.  
  679.     PROTOTYPE     ... void vnormalcur(void);
  680.  
  681.     ARGUMENTS     ... void
  682.  
  683.     RETURNS       ... void
  684.  
  685.  
  686.  
  687.  
  688.     ------------------------------------------------------------------------
  689.     NAME          ... vpopcur
  690.  
  691.     DESCRIPTION   ... Pops the last saved cursor configuration and position
  692.                       from the cursor save stack.
  693.  
  694.     PROTOTYPE     ... void vpopcur(void);
  695.  
  696.     ARGUMENTS     ... void
  697.  
  698.     RETURNS       ... void
  699.  
  700.  
  701.  
  702.     ------------------------------------------------------------------------
  703.     NAME          ... vpopscreen
  704.  
  705.     DESCRIPTION   ... Pops the last saved screen from the screen save stack.
  706.  
  707.     PROTOTYPE     ... void vpopscreen(void);
  708.  
  709.     ARGUMENTS     ... void
  710.  
  711.     RETURNS       ... void
  712.  
  713.  
  714.  
  715.     ------------------------------------------------------------------------
  716.     NAME          ... vpushcur
  717.  
  718.     DESCRIPTION   ... Saves the current cursor configuration and position
  719.                       to the cursor save stack.
  720.  
  721.     PROTOTYPE     ... void vpushcur(void);
  722.  
  723.     ARGUMENTS     ... void
  724.  
  725.     RETURNS       ... void
  726.  
  727.  
  728.     ------------------------------------------------------------------------
  729.     NAME          ... vpushscreen
  730.  
  731.     DESCRIPTION   ... Pushes (saves) an entire screen to the screen save
  732.                       stack. The stack is allocated in the far heap , The
  733.                       Turbo C enviroment (Turbo C editor & debugger) under
  734.                       normal conditions does not leave you much memory
  735.                       here, so you will have to change the options to make
  736.                       more of the far heap available.
  737.  
  738.     PROTOTYPE     ... int vpopscreen(void);
  739.  
  740.     ARGUMENTS     ... void
  741.  
  742.     RETURNS       ... 0          - No errors.
  743.                       -1         - Maximum screen saves exceeded.
  744.                       -2         - Out of memory, (far heap).
  745.  
  746.  
  747.  
  748.     ------------------------------------------------------------------------
  749.     NAME          ... vputch
  750.  
  751.     DESCRIPTION   ... Writes a char directly to the video memory with
  752.                       a specified attribute.
  753.  
  754.     PROTOTYPE     ... void vputch(int x, int y, unsigned char a,
  755.                                   register unsigned char c);
  756.  
  757.     ARGUMENTS     ... x            - The starting column.
  758.                       y            - The starting row.
  759.                       a            - The attribute to write in.
  760.                       c            - The char to write.
  761.  
  762.     RETURNS       ... void
  763.  
  764.  
  765.  
  766.     ------------------------------------------------------------------------
  767.     NAME          ... vputf
  768.  
  769.     DESCRIPTION   ... Writes a string directly to the video memory with
  770.                       a specified attribute, using a variable argument
  771.                       convention.
  772.  
  773.     PROTOTYPE     ... void vputf(int x, int y, unsigned char a,
  774.                                  char *fmt, ...);
  775.  
  776.     ARGUMENTS     ... x            - The starting column.
  777.                       y            - The starting row.
  778.                       a            - The attribute to write in.
  779.                       fmt          - The formated string to write.
  780.  
  781.     RETURNS       ... void
  782.  
  783.  
  784.  
  785.     ------------------------------------------------------------------------
  786.     NAME          ... vputfc
  787.  
  788.     DESCRIPTION   ... Writes a centered string directly to the video memory
  789.                       with  a specified attribute, using a variable argument
  790.                       convention.
  791.  
  792.     PROTOTYPE     ... void vputfc(int y, unsigned char a, char *fmt, ...);
  793.  
  794.     ARGUMENTS     ... y            - The starting row.
  795.                       a            - The attribute to write in.
  796.                       s            - The formatted string to write.
  797.  
  798.     RETURNS       ... void
  799.  
  800.  
  801.  
  802.     ------------------------------------------------------------------------
  803.     NAME          ... vputs
  804.  
  805.     DESCRIPTION   ... Writes a string directly to the video memory with
  806.                       a specified attribute.
  807.  
  808.     PROTOTYPE     ... void vputs(int x, int y, unsigned char a,
  809.                                  register char *cp);
  810.  
  811.     ARGUMENTS     ... x            - The starting column.
  812.                       y            - The starting row.
  813.                       a            - The attribute to write in.
  814.                       cp           - The string to write.
  815.  
  816.     RETURNS       ... void
  817.  
  818.  
  819.  
  820.     ------------------------------------------------------------------------
  821.     NAME          ... vputsc
  822.  
  823.     DESCRIPTION   ... Writes a centered string directly to the video memory
  824.                       with  a specified attribute.
  825.  
  826.     PROTOTYPE     ... void vputsc(int y, unsigned char a, char *s);
  827.  
  828.     ARGUMENTS     ... y            - The starting row.
  829.                       a            - The attribute to write in.
  830.                       s            - The string to write.
  831.  
  832.     RETURNS       ... void
  833.  
  834.  
  835.  
  836.     ------------------------------------------------------------------------
  837.     NAME          ... vset25
  838.  
  839.     DESCRIPTION   ... Sets the video adaptor to display 25 lines per screen.
  840.  
  841.     PROTOTYPE     ... void vset25(void);
  842.  
  843.     ARGUMENTS     ... void
  844.  
  845.     RETURNS       ... void
  846.  
  847.     ------------------------------------------------------------------------
  848.     NAME          ... vset43
  849.  
  850.     DESCRIPTION   ... Sets the video adaptor to display 43 lines per screen.
  851.                       This is only possible on EGA and VGA systems.
  852.  
  853.     PROTOTYPE     ... void vset43(void);
  854.  
  855.     ARGUMENTS     ... void
  856.  
  857.     RETURNS       ... void
  858.  
  859.     ------------------------------------------------------------------------
  860.     NAME          ... vset50
  861.  
  862.     DESCRIPTION   ... Sets the video adaptor to display 50 lines per screen.
  863.                       This is only possible on EGA and VGA systems.
  864.  
  865.     PROTOTYPE     ... void vset50(void);
  866.  
  867.     ARGUMENTS     ... void
  868.  
  869.     RETURNS       ... void
  870.  
  871.  
  872.  
  873.     ------------------------------------------------------------------------
  874.     NAME          ... vsetcur
  875.  
  876.     DESCRIPTION   ... Positions the cursor at the specified coordinates.
  877.  
  878.     PROTOTYPE     ... void vsetcur(int x, int y);
  879.  
  880.     ARGUMENTS     ... x            - The starting column.
  881.                       y            - The starting row.
  882.  
  883.     RETURNS       ... void
  884.  
  885.  
  886.     ------------------------------------------------------------------------
  887.     NAME          ... vsetcurtype
  888.  
  889.     DESCRIPTION   ... Sets the cursor for a particular appearance. Refer to
  890.                       the IBM manual on Interrupt 0x10 for charactersitics.
  891.  
  892.     PROTOTYPE     ... void vsetcurtype(unsigned t);
  893.  
  894.     ARGUMENTS     ... t            - The cursor type.
  895.  
  896.     RETURNS       ... void
  897.  
  898.  
  899.  
  900.     ------------------------------------------------------------------------
  901.     NAME          ... vshowcur
  902.  
  903.     DESCRIPTION   ... Unhides the cursor, this is usually called some time
  904.                       after the vhidecur function to make the cursor
  905.                       visible again.
  906.  
  907.     PROTOTYPE     ... void vshowcur(void);
  908.  
  909.     ARGUMENTS     ... void
  910.  
  911.     RETURNS       ... void
  912.  
  913.  
  914.  
  915.  
  916.  
  917.  
  918.     4.2  Keyboard functions:
  919.     ------------------------
  920.  
  921.  
  922.  
  923.     ------------------------------------------------------------------------
  924.     NAME          ... kgetch
  925.  
  926.     DESCRIPTION   ... Gets a character from the keyboard and hooks to a
  927.                       help function if the help key is pressed. The global
  928.                       variable help_key is set to F1 by default, but may
  929.                       be overwritten by re-assignment.
  930.                       This function discards any extended keystrokes,
  931.                       returning only when a non-extended keystroke is
  932.                       available, see kgetche() for extended keystrokes.
  933.  
  934.     PROTOTYPE     ... unsigned int kgetch(void);
  935.  
  936.     ARGUMENTS     ... void
  937.  
  938.     RETURNS       ... The character received.
  939.                       HIGH order 8 bits = scan code.
  940.                       LO   order 8 bits = ASCII char.
  941.                       see <sstkey.h> for key definitions.
  942.  
  943.  
  944.  
  945.     ------------------------------------------------------------------------
  946.     NAME          ... kgetche
  947.  
  948.     DESCRIPTION   ... Gets a character from the keyboard and hooks to a
  949.                       help function if the help key is pressed. The global
  950.                       variable help_key is set to F1 by default, but may
  951.                       be overwritten by re-assignment.
  952.                       This function supports extended keystrokes (F11 & F12
  953.                       etc).
  954.  
  955.     PROTOTYPE     ... unsigned int kgetche(void);
  956.  
  957.     ARGUMENTS     ... void
  958.  
  959.     RETURNS       ... The character received.
  960.                       HIGH order 8 bits = scan code.
  961.                       LO   order 8 bits = ASCII char.
  962.                       see <sstkey.h> for key definitions.
  963.  
  964.  
  965.     ------------------------------------------------------------------------
  966.     NAME          ... kkeyhit
  967.  
  968.     DESCRIPTION   ... Tests if a key has been pressed. This function
  969.                       supports extended keystrokes.
  970.  
  971.     PROTOTYPE     ... int kkeyhit(void);
  972.  
  973.     ARGUMENTS     ... void
  974.  
  975.     RETURNS       ... TRUE        - Key has been hit.
  976.                       FALSE       - No key has been hit.
  977.  
  978.  
  979.  
  980.     ------------------------------------------------------------------------
  981.     NAME          ... kstate
  982.  
  983.     DESCRIPTION   ... Test the state of all the special keys by using a bios
  984.                       call. The function returns a 16 bit word holding the
  985.                       state of the keys. The following constants may be used
  986.                       in determining if a key is pressed by ANDing the
  987.                       returned result.
  988.  
  989.                              K_RIGHTSHIFTDOWN     - right shift key is down.
  990.                              K_LEFTSHIFTDOWN      - left shift key is down.
  991.                              K_CTRLSHIFTDOWN      - ctrl shift keys are down.
  992.                              K_ALTSHIFTDOWN       - alt shift keys are down.
  993.                              K_SCROLLLOCKON       - scroll-lock key is on.
  994.                              K_NUMLOCKON          - num-lock key is on.
  995.                              K_CAPSLOCKON         - caps-lock key is on.
  996.                              K_INSON              - insert key is on.
  997.                              K_CTRLNUMLOCKON      - ctrl num-lock keys are on.
  998.                              K_SCROLLLOCKDOWN     - scroll-lock key is down.
  999.                              K_NUMLOCKDOWN        - num-lock key is down.
  1000.                              K_CAPSLOCKDOWN       - caps-lock key is down.
  1001.                              K_INSDOWN            - insert key is down.
  1002.  
  1003.  
  1004.     PROTOTYPE     ... int far *kstate(void);
  1005.  
  1006.     ARGUMENTS     ... void
  1007.  
  1008.     RETURNS       ... Far pointer to an integer (16 bit word) of the key
  1009.                       states.
  1010.  
  1011.  
  1012.  
  1013.  
  1014.  
  1015.     4.3  Mouse functions:
  1016.     ---------------------
  1017.  
  1018.  
  1019.  
  1020.     ------------------------------------------------------------------------
  1021.     NAME          ... msdleftpressed
  1022.  
  1023.     DESCRIPTION   ... Tests if the left mouse button has been pressed twice.
  1024.                       This is used in selecting items where the mouse needs
  1025.                       to be clicked twice within a certain time period. The
  1026.                       time period is preset and is optimised to give the
  1027.                       same performance as the IDE.
  1028.  
  1029.     PROTOTYPE     ... int msdleftpressed(void);
  1030.  
  1031.     ARGUMENTS     ... void
  1032.  
  1033.     RETURNS       ... !0           - The left button has been pressed
  1034.                                      twice.
  1035.                       0            - The left button has not been pressed
  1036.                                      twice.
  1037.  
  1038.  
  1039.  
  1040.     ------------------------------------------------------------------------
  1041.     NAME          ... msdrightpressed
  1042.  
  1043.     DESCRIPTION   ... Tests if the right mouse button has been pressed twice.
  1044.                       This is used in selecting items where the mouse needs
  1045.                       to be clicked twice within a certain time period. The
  1046.                       time period is preset and is optimised to give the
  1047.                       same performance as the IDE.
  1048.  
  1049.     PROTOTYPE     ... int msdrightpressed(void);
  1050.  
  1051.     ARGUMENTS     ... void
  1052.  
  1053.     RETURNS       ... TRUE         - The right button has been pressed
  1054.                                      twice.
  1055.                       FALSE        - The right button has not been pressed
  1056.                                      twice.
  1057.  
  1058.  
  1059.     ------------------------------------------------------------------------
  1060.     NAME          ... msgetch
  1061.  
  1062.     DESCRIPTION   ... Suspends execution until a mouse button is pressed.
  1063.  
  1064.     PROTOTYPE     ... #define msgetch()  while(mspressed());
  1065.  
  1066.     ARGUMENTS     ... void
  1067.  
  1068.     RETURNS       ... void
  1069.  
  1070.  
  1071.     ------------------------------------------------------------------------
  1072.     NAME          ... msgetpos
  1073.  
  1074.     DESCRIPTION   ... Gets the mouse coordinates.
  1075.  
  1076.     PROTOTYPE     ... void msgetpos(int *x, int *y);
  1077.  
  1078.     ARGUMENTS     ... x            - The starting column.
  1079.                       y            - The starting row.
  1080.  
  1081.     RETURNS       ... void
  1082.  
  1083.  
  1084.  
  1085.     ------------------------------------------------------------------------
  1086.     NAME          ... mshide
  1087.  
  1088.     DESCRIPTION   ... Hides the mouse cursor making it invisible.
  1089.  
  1090.     PROTOTYPE     ... void mshide(void);
  1091.  
  1092.     ARGUMENTS     ... void
  1093.  
  1094.     RETURNS       ... void
  1095.  
  1096.  
  1097.  
  1098.     ------------------------------------------------------------------------
  1099.     NAME          ... msinstalled
  1100.  
  1101.     DESCRIPTION   ... Tests to see if the mouse driver is installed.
  1102.  
  1103.     PROTOTYPE     ... int msinstalled(void);
  1104.  
  1105.     ARGUMENTS     ... void
  1106.  
  1107.     RETURNS       ... TRUE         - Mouse is installed.
  1108.                       FALSE        - Mouse is not installed.
  1109.  
  1110.  
  1111.     ------------------------------------------------------------------------
  1112.     NAME          ... msleftpressed
  1113.  
  1114.     DESCRIPTION   ... Tests if the left mouse button has been pressed.
  1115.  
  1116.     PROTOTYPE     ... #define msleftpressed()  (mspressed()&1)
  1117.  
  1118.     ARGUMENTS     ... void
  1119.  
  1120.     RETURNS       ... TRUE         - The left button has been pressed.
  1121.                       FALSE        - The left button has not been pressed.
  1122.  
  1123.  
  1124.  
  1125.     ------------------------------------------------------------------------
  1126.     NAME          ... mspressed
  1127.  
  1128.     DESCRIPTION   ... Tests if the mouse buttons are pressed.
  1129.  
  1130.     PROTOTYPE     ... int mspressed(void);
  1131.  
  1132.     ARGUMENTS     ... void
  1133.  
  1134.     RETURNS       ... TRUE         -  The mouse buttons are pressed.
  1135.                       FALSE        -  The mouse buttons are not pressed.
  1136.  
  1137.  
  1138.  
  1139.     ------------------------------------------------------------------------
  1140.     NAME          ... msreleased
  1141.  
  1142.     DESCRIPTION   ... Tests if a mouse button has been released.
  1143.  
  1144.     PROTOTYPE     ... int msreleased(void);
  1145.  
  1146.     ARGUMENTS     ... void
  1147.  
  1148.     RETURNS       ... TRUE         - The mouse button has been released.
  1149.                       FALSE        - The mouse button has not been
  1150.                                      released.
  1151.  
  1152.  
  1153.     ------------------------------------------------------------------------
  1154.     NAME          ... msreset
  1155.  
  1156.     DESCRIPTION   ... Resets the mouse.
  1157.  
  1158.     PROTOTYPE     ... void msreset(void);
  1159.  
  1160.     ARGUMENTS     ... void
  1161.  
  1162.     RETURNS       ... void
  1163.  
  1164.  
  1165.     ------------------------------------------------------------------------
  1166.     NAME          ... msrightpressed
  1167.  
  1168.     DESCRIPTION   ... Tests if the right mouse button has been pressed.
  1169.  
  1170.     PROTOTYPE     ... #define msrightpressed()   (mspressed()&2)
  1171.  
  1172.     ARGUMENTS     ... void
  1173.  
  1174.     RETURNS       ... TRUE         - The right button has been pressed.
  1175.                       FALSE        - The right button has not been pressed.
  1176.  
  1177.  
  1178.  
  1179.  
  1180.     ------------------------------------------------------------------------
  1181.     NAME          ... mssetpos
  1182.  
  1183.     DESCRIPTION   ... Positions the mouse cursor at a specific location.
  1184.  
  1185.     PROTOTYPE     ... void mssetpos(int x, int y);
  1186.  
  1187.     ARGUMENTS     ... x            - The starting column.
  1188.                       y            - The starting row.
  1189.  
  1190.     RETURNS       ... void
  1191.  
  1192.  
  1193.     ------------------------------------------------------------------------
  1194.     NAME          ... mssettravel
  1195.  
  1196.     DESCRIPTION   ... Sets the mouse travel limits.
  1197.  
  1198.     PROTOTYPE     ... void mssettravel(int minx, int maxx,
  1199.                                            int miny, int maxy);
  1200.  
  1201.     ARGUMENTS     ... minx         - Minimum starting column.
  1202.                       maxx         - Maximum ending column.
  1203.                       miny         - Minimum starting row.
  1204.                       maxy         - Maximum ending row.
  1205.  
  1206.     RETURNS       ... void
  1207.  
  1208.  
  1209.  
  1210.     ------------------------------------------------------------------------
  1211.     NAME          ... msshow
  1212.  
  1213.     DESCRIPTION   ... Enables the mouse cursor, making it visible.
  1214.  
  1215.     PROTOTYPE     ... void msshow(void)
  1216.  
  1217.     ARGUMENTS     ... void
  1218.  
  1219.     RETURNS       ... void
  1220.  
  1221.  
  1222.  
  1223.  
  1224.  
  1225.  
  1226.     4.4  String functions:
  1227.     ----------------------
  1228.  
  1229.  
  1230.  
  1231.     ------------------------------------------------------------------------
  1232.     NAME         ... strchangechar
  1233.  
  1234.     DESCRIPTION  ... Finds all letters in a string matching one character
  1235.                      and replaces them with another, observing case when
  1236.                      replacing.
  1237.  
  1238.     PROTOTYPE    ... int  strchangechar(char *s, int a, int b);
  1239.  
  1240.     ARGUMENTS    ... s             - String to search.
  1241.                      a             - Char to search for.
  1242.                      b             - Char to replace with.
  1243.  
  1244.     RETURNS      ... The number of matches found.
  1245.  
  1246.  
  1247.     ------------------------------------------------------------------------
  1248.     NAME         ... strchangestr
  1249.  
  1250.     DESCRIPTION  ... Changes all occurrences of one string to another,
  1251.                      obsering case when replacing.
  1252.  
  1253.     PROTOTYPE    ... char *strchangestr(char *s, char *a, char *b);
  1254.  
  1255.     ARGUMENTS    ... s             -  String to search.
  1256.                      a             -  String to search for.
  1257.                      b             -  String to replace found strings.
  1258.  
  1259.     RETURNS      ... The address of the modified string, or NULL if no
  1260.                      matches were found.
  1261.  
  1262.  
  1263.  
  1264.     ------------------------------------------------------------------------
  1265.     NAME         ... strchecksum
  1266.  
  1267.     DESCRIPTION  ... Calculates the checksum of a string. The checksum is
  1268.                      calculated by adding up the ASCII values of each
  1269.                      character in the string.
  1270.  
  1271.     PROTOTYPE    ... unsigned long strchecksum(char *s);
  1272.  
  1273.     ARGUMENTS    ... s             -  String to checksum.
  1274.  
  1275.     RETURNS      ... The checksum of the input string.
  1276.  
  1277.  
  1278.  
  1279.     ------------------------------------------------------------------------
  1280.     NAME         ... strcode
  1281.  
  1282.     DESCRIPTION  ... Encodes/decodes a string. Call this function to encode
  1283.                      a string, then call again using the same key to decode
  1284.                      it.  When reading or writing from a disk file, be sure
  1285.                      to open the file in binary mode.
  1286.  
  1287.  
  1288.     PROTOTYPE    ... char *strcode(char *s, char *k);
  1289.  
  1290.     ARGUMENTS    ... s             -  String to encode/decode.
  1291.                      k             -  Key string.
  1292.  
  1293.     RETURNS      ... The address of the input string
  1294.  
  1295.  
  1296.  
  1297.     ------------------------------------------------------------------------
  1298.     NAME         ... strcountchar
  1299.  
  1300.     DESCRIPTION  ... Counts occurrences of a character in a string,
  1301.                      observing case of letters.
  1302.  
  1303.     PROTOTYPE    ... int  strcountchar(char *s, int c);
  1304.  
  1305.     ARGUMENTS    ... s             -  String to search.
  1306.                      c             -  Char to search for.
  1307.  
  1308.     RETURNS      ... The number of occurrences of the character in the
  1309.                      string.
  1310.  
  1311.  
  1312.  
  1313.     ------------------------------------------------------------------------
  1314.     NAME         ... strcountstr
  1315.  
  1316.     DESCRIPTION  ... Counts occurrences of one string within another,
  1317.                      observing case of letters.
  1318.  
  1319.     PROTOTYPE    ... int  strcountstr(char *a, char *s);
  1320.  
  1321.     ARGUMENTS    ... a             -  String to search for.
  1322.                      s             -  String to search.
  1323.  
  1324.     RETURNS      ... The number of times that string a occurs in
  1325.                      string s.
  1326.  
  1327.  
  1328.     ------------------------------------------------------------------------
  1329.     NAME         ... strcvt
  1330.  
  1331.     DESCRIPTION  ... Performs one or a number of conversions on a string,
  1332.                      according to the options provided. You can pass the
  1333.                      following pre-defined constants as the option
  1334.                      parameter and may OR them to perform multiple
  1335.                      operations.
  1336.  
  1337.  
  1338.     PROTOTYPE    ... char *strcvt(char *d, char *s, int option, int ml);
  1339.  
  1340.     ARGUMENTS    ... d             -  Destination string.
  1341.                      s             -  Source string.
  1342.                      option        -  Option required.
  1343.                                       NOBLANKS        - remove blanks
  1344.                                       NONONALPHA      - remove non
  1345.                                                         alphabetic chars
  1346.                                       NONONNUMERIC    - remove non numeric
  1347.                                                         chars
  1348.                                       NOLEADBLANKS    - remove leading
  1349.                                                         blanks
  1350.                                       NOTRAILBLANKS   - remove trailing
  1351.                                                         blanks
  1352.                                       NOALPHA         - remove alphabetic
  1353.                                                         chars
  1354.                                       NONUMERIC       - remove numeric chars
  1355.                                       NOPUNCT         - remove punctuation
  1356.                                       TOSINGLE        - convert multiple
  1357.                                                         blanks to single
  1358.                                       TOUPPER         - convert lower case
  1359.                                                         chars to upper
  1360.                                       TOLOWER         - convert upper case
  1361.                                                         chars to lower
  1362.                                       TOPROPER        - capitalize all words
  1363.                                       TOUNPROPER      - un - capitalize all
  1364.                                                         words
  1365.                                       TONOCR          - remove all CR's
  1366.  
  1367.                      ml            -  Maximum length of string.
  1368.  
  1369.     RETURNS      ... Address of the modified string, or NULL if substring
  1370.                      not found.
  1371.  
  1372.  
  1373.  
  1374.     ------------------------------------------------------------------------
  1375.     NAME         ... strdelete
  1376.  
  1377.     DESCRIPTION  ... Deletes a substring from within a string, observing
  1378.                      case when deleting.
  1379.  
  1380.     RETURNS      ... char *strdelete(char *a, char *s);
  1381.  
  1382.     ARGUMENTS    ... a             -  Substring to delete.
  1383.                      s             -  String to delete from.
  1384.  
  1385.     RETURNS      ... Address of the modified string, or NULL if substring
  1386.                      not found.
  1387.  
  1388.  
  1389.  
  1390.  
  1391.     ------------------------------------------------------------------------
  1392.     NAME         ... strdeleteall
  1393.  
  1394.     DESCRIPTION  ... Deletes all occurrences of a substring from within a
  1395.                      string, observing case of letters.
  1396.  
  1397.     PROTOTYPE    ... char *strdeleteall(char *a, char *s);
  1398.  
  1399.     ARGUMENTS    ... a             -  Substring to delete.
  1400.                      s             -  String to delete from.
  1401.  
  1402.     RETURNS      ... Address of the modified string, or NULL if substring
  1403.                      not found.
  1404.  
  1405.  
  1406.  
  1407.  
  1408.     ------------------------------------------------------------------------
  1409.     NAME         ... strichangestr
  1410.  
  1411.     DESCRIPTION  ... Changes all occurrences of one string to another,
  1412.                      ignoreing case when replacing.
  1413.  
  1414.     PROTOTYPE    ... char *strichangestr(char *s, char *a, char *b);
  1415.  
  1416.     ARGUMENTS    ... s             -  String to search.
  1417.                      a             -  String to search for.
  1418.                      b             -  String to replace found strings.
  1419.  
  1420.     RETURNS      ... The address of the modified string, or NULL if no
  1421.                      matches were found.
  1422.  
  1423.  
  1424.  
  1425.     ------------------------------------------------------------------------
  1426.     NAME         ... strichecksum
  1427.  
  1428.     DESCRIPTION  ... Calculates the checksum of a string. The checksum is
  1429.                      calculated by adding up the ASCII values of each
  1430.                      character in the string, all lower-case letters will
  1431.                      be translated as upper-case.
  1432.  
  1433.     PROTOTYPE    ... unsigned long strichecksum(char *s);
  1434.  
  1435.     ARGUMENTS    ... s             -  String to checksum.
  1436.  
  1437.     RETURNS      ... The checksum of the input string.
  1438.  
  1439.  
  1440.  
  1441.     ------------------------------------------------------------------------
  1442.     NAME         ... stricountchar
  1443.  
  1444.     DESCRIPTION  ... Counts occurrences of a character in a string,
  1445.                      ignoring case of letters.
  1446.  
  1447.     PROTOTYPE    ... int  stricountchar(char *s, int c);
  1448.  
  1449.     ARGUMENTS    ... s             -  String to search.
  1450.                      c             -  Char to search for.
  1451.  
  1452.     RETURNS      ... The number of occurrences of the character in the
  1453.                      string.
  1454.  
  1455.  
  1456.     ------------------------------------------------------------------------
  1457.     NAME         ... stricountstr
  1458.  
  1459.     DESCRIPTION  ... Counts occurrences of one string within another,
  1460.                      ignoring case of letters.
  1461.  
  1462.     PROTOTYPE    ... int  stricountstr(char *a, char *s);
  1463.  
  1464.     ARGUMENTS    ... a             -  String to search for.
  1465.                      s             -  String to search.
  1466.  
  1467.     RETURNS      ... The number of times that string a occurs in
  1468.                      string s.
  1469.  
  1470.  
  1471.     ------------------------------------------------------------------------
  1472.     NAME         ... stridelete
  1473.  
  1474.     DESCRIPTION  ... Deletes a substring from within a string, ingoring
  1475.                      case when deleting.
  1476.  
  1477.     RETURNS      ... char *stridelete(char *a, char *s);
  1478.  
  1479.     ARGUMENTS    ... a             -  Substring to delete.
  1480.                      s             -  String to delete from.
  1481.  
  1482.     RETURNS      ... Address of the modified string, or NULL if substring
  1483.                      not found.
  1484.  
  1485.  
  1486.  
  1487.     ------------------------------------------------------------------------
  1488.     NAME         ... strideleteall
  1489.  
  1490.     DESCRIPTION  ... Deletes all occurrences of a substring from within a
  1491.                      string, ignoring case of letters.
  1492.  
  1493.     PROTOTYPE    ... char *strideleteall(char *a, char *s);
  1494.  
  1495.     ARGUMENTS    ... a             -  Substring to delete.
  1496.                      s             -  String to delete from.
  1497.  
  1498.     RETURNS      ... Address of the modified string, or NULL if substring
  1499.                      not found.
  1500.  
  1501.  
  1502.  
  1503.     ------------------------------------------------------------------------
  1504.     NAME         ... striinc
  1505.  
  1506.     DESCRIPTION  ... Determines if and where one string is included within
  1507.                      another, ignoring case of letters.
  1508.  
  1509.     PROTOTYPE    ... char *striinc(char *a, char *s);
  1510.  
  1511.     ARGUMENTS    ... a             -  String to search for.
  1512.                      s             -  String to search.
  1513.  
  1514.     RETURNS      ... A pointer to the location in 's' that contains 'a',
  1515.                      or NULL if not found.
  1516.  
  1517.  
  1518.     ------------------------------------------------------------------------
  1519.     NAME         ... strinc
  1520.  
  1521.     DESCRIPTION  ... Determines if and where one string is included within
  1522.                      another, obseriving case of letters.
  1523.  
  1524.     PROTOTYPE    ... char *strinc(char *a, char *s);
  1525.  
  1526.     ARGUMENTS    ... a             -  String to search for.
  1527.                      s             -  String to search.
  1528.  
  1529.     RETURNS      ... A pointer to the location in 's' that contains 'a',
  1530.                      or NULL if not found.
  1531.  
  1532.  
  1533.  
  1534.     ------------------------------------------------------------------------
  1535.     NAME         ... strinsert
  1536.  
  1537.     DESCRIPTION  ... Inserts one string into another.
  1538.  
  1539.     PROTOTYPE    ... char *strinsert(char *a, char *s, int p);
  1540.  
  1541.     ARGUMENTS    ... a             -  String to insert.
  1542.                      s             -  String to receive insertion.
  1543.                      p             -  Starting position.
  1544.  
  1545.     RETURNS      ... The address of the modified string.
  1546.  
  1547.  
  1548.  
  1549.     ------------------------------------------------------------------------
  1550.     NAME         ... strisblank
  1551.  
  1552.     DESCRIPTION  ... Determines if a given string is blank (whitespace).
  1553.  
  1554.     PROTOTYPE    ... int  strisblank(char *s);
  1555.  
  1556.     ARGUMENTS    ... s             -  String to check.
  1557.  
  1558.     RETURNS      ... TRUE if string is blank, FALSE otherwise
  1559.  
  1560.  
  1561.  
  1562.  
  1563.     ------------------------------------------------------------------------
  1564.     NAME         ... strisrep
  1565.  
  1566.     DESCRIPTION  ... Searches for, and replaces one string within another,
  1567.                      ignoring case of letters.
  1568.  
  1569.     PROTOTYPE    ... char *strisrep(char *s, char *a, char *b);
  1570.  
  1571.     ARGUMENTS    ... s             -  String to search.
  1572.                      a             -  String to search for.
  1573.                      b             -  String to replace with.
  1574.  
  1575.     RETURNS      ... The address of the modified string, or NULL if the
  1576.                      search string wasn't found.
  1577.  
  1578.  
  1579.     ------------------------------------------------------------------------
  1580.     NAME         ... strleft
  1581.  
  1582.     DESCRIPTION  ... Create a new string from left or right by taking a
  1583.                      specified portion of a string from its left and
  1584.                      creates a new string.
  1585.  
  1586.     PROTOTYPE    ... char *strleft(char *s, int n);
  1587.  
  1588.     ARGUMENTS    ... s             -  String used for input.
  1589.                      n             -  Number of chars to copy.
  1590.  
  1591.     RETURNS      ... Address of the newly created string or a NULL if a
  1592.                      memory allocation error occurred.
  1593.  
  1594.  
  1595.     ------------------------------------------------------------------------
  1596.     NAME         ... strljust
  1597.  
  1598.     DESCRIPTION  ... Left justifies a string.
  1599.  
  1600.     PROTOTYPE    ... char *strljust(char *s);
  1601.  
  1602.     ARGUMENTS    ... s             -  String to justify.
  1603.  
  1604.     RETURNS      ... Address of the modified string.
  1605.  
  1606.  
  1607.  
  1608.     ------------------------------------------------------------------------
  1609.     NAME         ... strmiddle
  1610.  
  1611.     DESCRIPTION  ... Create a new string from part of an input string by
  1612.                      taking a section from input string starting at given
  1613.                      position and taking the given amount of characters
  1614.                      creating a new string.
  1615.  
  1616.     PROTOTYPE    ... char *strmiddle(char *s, int p, int n);
  1617.  
  1618.     ARGUMENTS    ... s             -  String used for input.
  1619.                      p             -  Position to start copying.
  1620.                      n             -  Number of chars to copy.
  1621.  
  1622.     RETURNS      ... Address of the newly created string or a NULL if a
  1623.                      memory allocation error occurred.
  1624.  
  1625.  
  1626.  
  1627.     ------------------------------------------------------------------------
  1628.     NAME         ... strresize
  1629.  
  1630.     DESCRIPTION  ... Adjusts the length of a string, either by truncation or
  1631.                      padding with spaces.
  1632.  
  1633.     PROTOTYPE    ... char *strresize(char *s, int n);
  1634.  
  1635.     ARGUMENTS    ... s             -  String use for input.
  1636.                      n             -  New length.
  1637.  
  1638.     RETURNS      ... Address of the modified string.
  1639.  
  1640.  
  1641.  
  1642.     ------------------------------------------------------------------------
  1643.     NAME         ... strright
  1644.  
  1645.     DESCRIPTION  ... Create a new string from left or right by takeing a
  1646.                      specified portion of a string from its right and
  1647.                      creates a new string.
  1648.  
  1649.     PROTOTYPE    ... char *strright(char *s, int n);
  1650.  
  1651.     ARGUMENTS    ... s             -  String used for input.
  1652.                      n             -  Number of chars to copy.
  1653.  
  1654.     RETURNS      ... Address of the newly created string or a NULL if a
  1655.                      memory allocation error occurred.
  1656.  
  1657.  
  1658.     ------------------------------------------------------------------------
  1659.     NAME         ... strrjust
  1660.  
  1661.     DESCRIPTION  ... Right justifies a string.
  1662.  
  1663.     PROTOTYPE    ... char *strrjust(char *s);
  1664.  
  1665.     ARGUMENTS    ... s             -  String to justify.
  1666.  
  1667.     RETURNS      ... Address of the modified string.
  1668.  
  1669.  
  1670.  
  1671.     ------------------------------------------------------------------------
  1672.     NAME         ... strrotleft
  1673.  
  1674.     DESCRIPTION  ... Rotates a string specified number of characters left.
  1675.                      The rotated characters wrap around to the opposite
  1676.                      side of the string.
  1677.  
  1678.     PROTOTYPE    ... char *strrotleft(char *s, int n);
  1679.  
  1680.     ARGUMENTS    ... s             -  String to rotate.
  1681.                      n             -  Count to rotate.
  1682.  
  1683.     RETURNS      ... Address of the modified string
  1684.  
  1685.  
  1686.     ------------------------------------------------------------------------
  1687.     NAME         ... strrotright
  1688.  
  1689.     DESCRIPTION  ... Rotates a string specified number of characters right.
  1690.                      The rotated characters wrap around to the opposite
  1691.                      side of the string.
  1692.  
  1693.     PROTOTYPE    ... char *strrotright(char *s, int n);
  1694.  
  1695.     ARGUMENTS    ... s             -  String to rotate
  1696.                      n             -  Count to rotate
  1697.  
  1698.     RETURNS      ... Address of the modified string.
  1699.  
  1700.  
  1701.  
  1702.     ------------------------------------------------------------------------
  1703.     NAME         ... strshiftleft
  1704.  
  1705.     DESCRIPTION  ... Shifts a string a specified number of characters left
  1706.                      Characters that shift past the beginning of the string
  1707.                      "drop off" and spaces are added to the right of the
  1708.                      string.
  1709.  
  1710.     PROTOTYPE    ... char *strshiftleft(char *s, int n);
  1711.  
  1712.     ARGUMENTS    ... s             -  String to shift.
  1713.                      n             -  Char count to shift.
  1714.  
  1715.     RETURNS      ... Address of the Modified string
  1716.  
  1717.  
  1718.     ------------------------------------------------------------------------
  1719.     NAME         ... strshiftright
  1720.  
  1721.     DESCRIPTION  ... Shifts a string a specified number of characters right
  1722.                      Characters that shift past the end of the string
  1723.                      "drop off" and spaces are added to the left of the
  1724.                      string.
  1725.  
  1726.     PROTOTYPE    ... char *strshiftright(char *s, int n);
  1727.  
  1728.     ARGUMENTS    ... s             -  String to shift.
  1729.                      n             -  Char count to shift.
  1730.  
  1731.     RETURNS      ... Address of the Modified string
  1732.  
  1733.  
  1734.  
  1735.     ------------------------------------------------------------------------
  1736.     NAME         ... strsrep
  1737.  
  1738.     DESCRIPTION  ... Searches for, and replaces one string within another,
  1739.                      observing case of letters.
  1740.  
  1741.     PROTOTYPE    ... char *strsrep(char *s, char *a, char *b);
  1742.  
  1743.     ARGUMENTS    ... s             -  String to search.
  1744.                      a             -  String to search for.
  1745.                      b             -  String to replace with.
  1746.  
  1747.     RETURNS      ... The address of the modified string, or NULL if the
  1748.                      search string wasn't found.
  1749.  
  1750.  
  1751.  
  1752.  
  1753.     ------------------------------------------------------------------------
  1754.     NAME         ... struplow
  1755.  
  1756.     DESCRIPTION  ... Converts a string to mixed upper & lowercase characters.
  1757.                      Characters are forced to upper or lowercase depending
  1758.                      upon the previous character in the string.
  1759.  
  1760.     PROTOTYPE    ... char *struplow(char *s);
  1761.  
  1762.     ARGUMENTS    ... s             -  String to convert
  1763.  
  1764.     RETURNS      ... Address of the modified string
  1765.  
  1766.  
  1767.  
  1768.  
  1769.  
  1770.  
  1771.     4.5  Miscellaneous functions:
  1772.     -----------------------------
  1773.  
  1774.  
  1775.  
  1776.  
  1777.  
  1778.  
  1779.  
  1780.     4.6  FOSSIL functions:
  1781.     ----------------------
  1782.  
  1783.  
  1784.  
  1785.  
  1786.     -------------------------------------------------------------------------
  1787.     NAME          ... finit
  1788.  
  1789.     DESCRIPTION   ... Function 0x00.   Initialise a port.
  1790.  
  1791.     PROTOTYPE     ... unsigned int finit(unsigned int p, unsigned int b);
  1792.  
  1793.     PARAMETERS    ... p            - Port number.
  1794.                       b            - The desired port parameters (see
  1795.                                      below)
  1796.  
  1797.                       Setting the Parameters
  1798.                       ----------------------
  1799.                       The 16 bit word is used to set the port's Data Width,
  1800.                       Stop Bits, Parity and Baud Rate.  (The number is the
  1801.                       the sum of all the  appropriate binary bits indicated
  1802.                       below.). Note that only the lower order of the word
  1803.                       is used.
  1804.  
  1805.                          Bits 0 and 1 set the data word width:
  1806.                               00 = 5 bits wide
  1807.                               01 = 6 bits wide
  1808.                               10 = 7 bits wide
  1809.                               11 = 8 bits wide
  1810.  
  1811.                          Bit 2 sets the number of stop bits:
  1812.                               00 = 1 stop bit
  1813.                               01 = 2 stop bits
  1814.  
  1815.                          Bits 3 and 4 set the port's parity:
  1816.                               00 = no parity
  1817.                               01 = odd parity
  1818.                               10 = even parity
  1819.  
  1820.                          Bits 5, 6, and 7 set the port's baud rate:
  1821.                               000 = 19200 baud    100 = 1200 baud
  1822.                               001 = 38400 baud    101 = 2400 baud
  1823.                               010 = 300   baud    110 = 4800 baud
  1824.                               011 = 600   baud    111 = 9600 baud
  1825.  
  1826.  
  1827.                     Graphically, the byte looks like this:
  1828.  
  1829.                     bits 7 6 5   4 3   2   1 0
  1830.                          | | |   | |   |   | |
  1831.                          | | |   | |   |    - ----  Data Word Width
  1832.                          | | |   | |    ----------  Stop Bits
  1833.                          | | |    - --------------  Parity
  1834.                           - - --------------------  Baud Rate
  1835.  
  1836.  
  1837.     RETURNS       ... unsigned     - Bit 0-7   - Modem status.
  1838.                                      Bit 7     - Will be set if there is
  1839.                                                  an error.
  1840.                                      Bit 8-15  - Port and line status.
  1841.  
  1842.                                      See also fstatus() function.
  1843.  
  1844.  
  1845.     -------------------------------------------------------------------------
  1846.     NAME          ... fputch
  1847.  
  1848.     DESCRIPTION   ... Function 0x01.   Outputs a single char to the port
  1849.                       It places the character into the FOSSIL's transmit
  1850.                       queue.  If there is no room in the transmit buffer,
  1851.                       this call will wait until there is.  It is
  1852.                       recommended that this call should either be avoided
  1853.                       (use fpoke instead) or be used when room in the
  1854.                       buffer is  guaranteed, since there is a risk of this
  1855.                       call "hanging" the machine waiting for the buffer to
  1856.                       make room, and there is no check for a 'stuck'
  1857.                       transmitter.  Use fstatus to determine if there is
  1858.                       room.
  1859.  
  1860.  
  1861.     PROTOTYPE     ... unsigned int fputch(unsigned int p, char c);
  1862.  
  1863.     PARAMETERS    ... p            - Port number.
  1864.                       c            - The char to be sent.
  1865.  
  1866.     RETURNS       ... unsigned     - Bit 6-0 - port status.
  1867.                                      Bit 7   - set on error.
  1868.  
  1869.                                      See fstatus() for more info.
  1870.  
  1871.  
  1872.     -------------------------------------------------------------------------
  1873.     NAME          ... fgetch
  1874.  
  1875.     DESCRIPTION   ... Function 0x02.   Reads a single char from the port.
  1876.                       If there is a character available in the receive
  1877.                       buffer, it returns with the next character. It will
  1878.                       wait until a character is received if none are
  1879.                       available.
  1880.  
  1881.     PROTOTYPE     ... unsigned int fgetch(unsigned int p);
  1882.  
  1883.     PARAMETERS    ... p            - Port number.
  1884.  
  1885.     RETURNS       ... unsigned     - The char received.
  1886.  
  1887.  
  1888.  
  1889.     -------------------------------------------------------------------------
  1890.     NAME          ... fstatus
  1891.  
  1892.     DESCRIPTION   ... Function 0x03.   Gets the port status. The function
  1893.                       returns with the line and modem status. The must be
  1894.                       initialised (see finit).  For the meanings of the bit
  1895.                       flags refer to the Rev 5 FOSSIL spec.
  1896.  
  1897.     PROTOTYPE     ... unsigned int fstatus(unsigned int p);
  1898.  
  1899.     PARAMETERS    ... p            - Port number.
  1900.  
  1901.     RETURNS       ... unsigned     - A 16 bit word holding the status of the
  1902.                                      port, refer to the table below.
  1903.  
  1904.                                      Bit 7  - data carrier detect.
  1905.                                      Bit 8  - input data is
  1906.                                               available in buffer.
  1907.                                      Bit 13 - room is available in
  1908.                                               output buffer.
  1909.                                      Bit 14 - output buffer is empty.
  1910.  
  1911.  
  1912.  
  1913.  
  1914.     -------------------------------------------------------------------------
  1915.     NAME          ... ffinit
  1916.  
  1917.     DESCRIPTION   ... Function 0x04.  Initialise a port for FOSSIL
  1918.                       (bufferred and interrupt  driven) processing.  If
  1919.                       'fb' is used (it points to a byte location), the value
  1920.                       at that memory location will be incremented once every
  1921.                       time a ^C is entered at the local keyboard. If the 'f'
  1922.                       parameter is left as zero, it will be ignored, else it
  1923.                       should be the memory address of a structure to return
  1924.                       the FOSSIL driver's revision number and maximum
  1925.                       function call number (useful for testing a minimum
  1926.                       standard - the maximum  function number of a FOSSIL
  1927.                       revision 5 compatible driver is 0x1B. This function
  1928.                       returns a value 0x1954 if a FOSSIL driver is installed.
  1929.  
  1930.     PROTOTYPE     ... unsigned int ffinit(unsigned int p, unsigned int *f,
  1931.                                           char far *fb);
  1932.  
  1933.     PARAMETERS    ... p            - Port number.
  1934.                       f            - Byte flag for
  1935.                       fb           - Byte to be set upon ^C.
  1936.  
  1937.  
  1938.     RETURNS       ... unsigned     - F_SIGNATURE (0x1954) if sucessfull.
  1939.  
  1940.  
  1941.     -------------------------------------------------------------------------
  1942.     NAME          ... ffdeinit
  1943.  
  1944.     DESCRIPTION   ... Function 0x05.   Deinitialises the fossil driver.
  1945.                       This should be called to deinitialise the communcations
  1946.                       port and disable interrupt processing on the port.
  1947.                       This would turn off hardware communications interrupts
  1948.                       and route all communcations calls to the usual BIOS.
  1949.  
  1950.     PROTOTYPE     ... void ffdeinit(unsigned int p);
  1951.  
  1952.     PARAMETERS    ... p            - Port number.
  1953.  
  1954.     RETURNS       ... void
  1955.  
  1956.  
  1957.  
  1958.     -------------------------------------------------------------------------
  1959.     NAME          ... fdtr
  1960.  
  1961.     DESCRIPTION   ... Function 0x06.  Raises or lowers the DTR line of the
  1962.                       modem. Dropping DTR for a short period (say > .5 sec)
  1963.                       will normally force a modem to hang up.
  1964.  
  1965.     PROTOTYPE     ... void fdtr(unsigned int p, unsigned int d);
  1966.  
  1967.     PARAMETERS    ... p            - Port number.
  1968.                       d            -
  1969.  
  1970.     RETURNS       ... void
  1971.  
  1972.  
  1973.  
  1974.     -------------------------------------------------------------------------
  1975.     NAME          ... ftickparms
  1976.  
  1977.     DESCRIPTION   ... Function 0x07.   Get the timer tick parameters.
  1978.                       This is used to determine the parameters of the timer
  1979.                       tick on any given machine.
  1980.  
  1981.     PROTOTYPE     ... unsigned int ftickparms(unsigned int *ms);
  1982.  
  1983.     PARAMETERS    ... ms           - An integer pointer that get set to the
  1984.                                      approximate number of milliseconds
  1985.                                      per tick.
  1986.  
  1987.     RETURNS       ... unsigned     - Ticks per second on interrupt number
  1988.                                      in the AL register.
  1989.  
  1990.  
  1991.  
  1992.     -------------------------------------------------------------------------
  1993.     NAME          ... fflushout
  1994.  
  1995.     DESCRIPTION   ... Function 0x08.   Flush the output buffer and wait
  1996.                       until the entire output is empty. On return, the
  1997.                       transmit buffer is guaranteed to be empty.
  1998.  
  1999.     PROTOTYPE     ... void fflushout(unsigned int p);
  2000.  
  2001.     PARAMETERS    ... p            - Port number.
  2002.  
  2003.     RETURNS       ... void
  2004.  
  2005.  
  2006.     -------------------------------------------------------------------------
  2007.     NAME          ... fpurgeout
  2008.  
  2009.     DESCRIPTION   ... Function 0x09.   Purge the output buffer and throw
  2010.                       away all pending output.
  2011.  
  2012.     PROTOTYPE     ... void fpurgeout(unsigned int p);
  2013.  
  2014.     PARAMETERS    ... p            - Port number.
  2015.  
  2016.     RETURNS       ... void
  2017.  
  2018.  
  2019.     -------------------------------------------------------------------------
  2020.     NAME          ... fpurgein
  2021.  
  2022.     DESCRIPTION   ... Function 0x0A.   Purge the input buffer and throw
  2023.                       away all pending input.
  2024.  
  2025.     PROTOTYPE     ... void fpurgein(unsigned int p);
  2026.  
  2027.     PARAMETERS    ... p            - Port number.
  2028.  
  2029.     RETURNS       ... void
  2030.  
  2031.  
  2032.     -------------------------------------------------------------------------
  2033.     NAME          ... fpoke
  2034.  
  2035.     DESCRIPTION   ... Function 0x0B.   Send a char to a port without wait.
  2036.                       This call does not wait if there is no room available.
  2037.  
  2038.     PROTOTYPE     ... unsigned int fpoke(unsigned int p, char c);
  2039.  
  2040.     PARAMETERS    ... p            - Port number.
  2041.                       c            - The char to send.
  2042.  
  2043.     RETURNS       ... unsigned     - 0x00  - Char not accepted.
  2044.                                      0x01  - Char accepted.
  2045.  
  2046.  
  2047.     -------------------------------------------------------------------------
  2048.     NAME          ... fpeek
  2049.  
  2050.     DESCRIPTION   ... Function 0x0C.   Non-destructively reads a char from
  2051.                       the port. This does not take the received character out
  2052.                       of the buffer, and will be returned again by executing
  2053.                       fgetch.
  2054.  
  2055.  
  2056.     PROTOTYPE     ... unsigned int fpeek(unsigned int p);
  2057.  
  2058.     PARAMETERS    ... p            - Port number.
  2059.  
  2060.     RETURNS       ... unsigned     - The available char.
  2061.                                      F_NULL - If no char available.
  2062.  
  2063.  
  2064.  
  2065.     -------------------------------------------------------------------------
  2066.     NAME          ... fkbdpeek
  2067.  
  2068.     DESCRIPTION   ... Function 0x0D.   Non-destructively reads a char from
  2069.                       the keyboard without wait. This call does not flush
  2070.                       the key, which will be available again by calling
  2071.                       fkbdgetch.
  2072.  
  2073.     PROTOTYPE     ... unsigned int fkbdpeek(void);
  2074.  
  2075.     PARAMETERS    ... void
  2076.  
  2077.     RETURNS       ... unsigned     - A standard IBM scan code interpretation
  2078.                                      of the char read.
  2079.  
  2080.                                      F_NULL - If no char available.
  2081.  
  2082.  
  2083.  
  2084.     -------------------------------------------------------------------------
  2085.     NAME          ... fkbdgetch
  2086.  
  2087.     DESCRIPTION   ... Function 0x0E.   Get a character from the keyboard.
  2088.                       If one is not available, it waits until a key has been
  2089.                       hit.
  2090.  
  2091.     PROTOTYPE     ... unsigned int fkbdgetch(void);
  2092.  
  2093.     PARAMETERS    ... void
  2094.  
  2095.     RETURNS       ... unsigned     - A standard IBM scan code interpretation
  2096.                                      of the char read.
  2097.  
  2098.                                      F_NULL  - If no char available.
  2099.  
  2100.  
  2101.     -------------------------------------------------------------------------
  2102.     NAME          ... fflow
  2103.  
  2104.     DESCRIPTION   ... Function 0x0F.   Enable or disbale flow control,
  2105.                       allowing you to switch off and on XON/XOFF (or ^S/^Q)
  2106.                       and CTS/RTS handshaking.  If running a high speed modem
  2107.                       with the FOSSIL driver 'locked' at a particular baud
  2108.                       rate, you may find that CTS/RTS handshaking cannot be
  2109.                       controlled since this is automatically provided in
  2110.                       these circumstances. An additional flag (see FOSSIL
  2111.                       spec) allows finer control over the FOSSIL's
  2112.                       transmitter.
  2113.  
  2114.     PROTOTYPE     ... void fflow(unsigned int p, unsigned char m);
  2115.  
  2116.     PARAMETERS    ... p            - Port number.
  2117.                       m            - Bit mask describing flow control.
  2118.  
  2119.                                      0     - XON/XOFF on transmitt (watch
  2120.                                              for XOFF while sending).
  2121.                                      1     - CTS/RTS
  2122.                                      3     - XON/XOFF on receive (send XOFF
  2123.                                              when buffer is near full).
  2124.                                      4-7   - All 1.
  2125.  
  2126.     RETURNS       ... void
  2127.  
  2128.  
  2129.  
  2130.     -------------------------------------------------------------------------
  2131.     NAME          ... fcontrol
  2132.  
  2133.     DESCRIPTION   ... Function 0x10.   Enable or Disable extended ^C or ^K
  2134.                       checking (from remote).  If enabled, the FOSSIL
  2135.                       automatically makes ^C and ^K 'transparent' from the
  2136.                       remote (as are flow control XON and XOFFs), but
  2137.                       instead sets the flag returned by this call.
  2138.  
  2139.  
  2140.     PROTOTYPE     ... unsigned int fcontrol(unsigned int p, unsigned char m);
  2141.  
  2142.     PARAMETERS    ... p            - Port number.
  2143.                       m            - Bit mask for control.
  2144.                                      0x00  - Enable/disable ^C && ^K
  2145.                                              checking.
  2146.                                      0x01  - Enable/disable the transmitter.
  2147.  
  2148.     RETURNS       ... unsigned     - ???????????????????
  2149.  
  2150.  
  2151.  
  2152.     -------------------------------------------------------------------------
  2153.     NAME          ... fgotoxy
  2154.  
  2155.     DESCRIPTION   ... Function 0x11.   Sets the cursor at a specific
  2156.                       location.
  2157.  
  2158.     PROTOTYPE     ... void fgotoxy(unsigned int x, unsigned int y);
  2159.  
  2160.     PARAMETERS    ... x            - Starting column.
  2161.                       y            - Starting row.
  2162.  
  2163.     RETURNS       ... void
  2164.  
  2165.  
  2166.  
  2167.  
  2168.     -------------------------------------------------------------------------
  2169.     NAME          ... fwherexy
  2170.  
  2171.     DESCRIPTION   ... Function 0x12.   Gets the current cursor location.
  2172.  
  2173.     PROTOTYPE     ... unsigned int fwherexy(unsigned int *x,
  2174.                                             unsigned int *y);
  2175.  
  2176.     PARAMETERS    ... x            - Starting column.
  2177.                       y            - Starting row.
  2178.  
  2179.     RETURNS       ... unsigned     - ??????????????????????????
  2180.  
  2181.  
  2182.  
  2183.  
  2184.     -------------------------------------------------------------------------
  2185.     NAME          ... fdispansi
  2186.  
  2187.     DESCRIPTION   ... Function 0x13.   Writes a single char via ANSI to the
  2188.                       console.
  2189.  
  2190.     PROTOTYPE     ... void fdispansi(char c);
  2191.  
  2192.     PARAMETERS    ... c            - The char to write.
  2193.  
  2194.     RETURNS       ... void
  2195.  
  2196.  
  2197.  
  2198.     -------------------------------------------------------------------------
  2199.     NAME          ... fwatchdog
  2200.  
  2201.     DESCRIPTION   ... Function 0x14.  Enable/Disable watchdog carrier
  2202.                       processing.
  2203.  
  2204.     PROTOTYPE     ... void fwatchdog(unsigned int p, int f);
  2205.  
  2206.     PARAMETERS    ... p            - Port number.
  2207.                       f            - Processing mode
  2208.                                      0x00  - Disable
  2209.                                      0x01  - Enable
  2210.     RETURNS       ... void
  2211.  
  2212.  
  2213.  
  2214.     -------------------------------------------------------------------------
  2215.     NAME          ... fdispbios
  2216.  
  2217.     DESCRIPTION   ... Function 0x15.  Write a char to the console using
  2218.                       existing BIOS support routines.
  2219.  
  2220.     PROTOTYPE     ... void fdispbios(char c);
  2221.  
  2222.     PARAMETERS    ... c            - The char to write.
  2223.  
  2224.     RETURNS       ... void
  2225.  
  2226.  
  2227.  
  2228.  
  2229.     -------------------------------------------------------------------------
  2230.     NAME          ... ftickchain
  2231.  
  2232.     DESCRIPTION   ... Function 0x16. Inserts/deletes a specified function
  2233.                       to/from a the timer tick chain.
  2234.  
  2235.     PROTOTYPE     ... unsigned int ftickchain(int a, void (far *func)());
  2236.  
  2237.     PARAMETERS    ... a            - Insert/Delete mode.
  2238.                                            0x00   - Delete.
  2239.                                            0x01   - Add.
  2240.                       func         - Address of function to insert/delete.
  2241.  
  2242.     RETURNS       ... unsigned     - 0x00   - Successful.
  2243.                                      0x01   - Unsuccessful.
  2244.  
  2245.  
  2246.  
  2247.     -------------------------------------------------------------------------
  2248.     NAME          ... freboot
  2249.  
  2250.     DESCRIPTION   ... Function 0x17. Reboots the system.
  2251.  
  2252.     PROTOTYPE     ... void freboot(unsigned int w);
  2253.  
  2254.     PARAMETERS    ... w            - Mode for bootstrap.
  2255.                                      0x00  - Cold boot.
  2256.                                      0x01  - Warm boot.
  2257.  
  2258.     RETURNS       ... void
  2259.  
  2260.  
  2261.  
  2262.     -------------------------------------------------------------------------
  2263.     NAME          ... fgetblk
  2264.  
  2265.     DESCRIPTION   ... Function 0x18. Reads a block of data from the port.
  2266.                       This call attempts to receive 'z' number of bytes from
  2267.                       port 'p' to the address 'buf'; it returns the number of
  2268.                       bytes actually received, which can be zero (if not is
  2269.                       available). Using this method is much faster than
  2270.                       individual calls to fgetch and is preferred in high
  2271.                       speed communications or intense activity (such as
  2272.                       during file transfers).
  2273.  
  2274.     PROTOTYPE     ... unsigned int fgetblk(unsigned int p, void far *buf,
  2275.                                            unsigned int z);
  2276.  
  2277.     PARAMETERS    ... p            - Port number.
  2278.                       buf          - Buffer for received chars.
  2279.                       z            - Maximum number of chars to transfer
  2280.                                      to buffer.
  2281.  
  2282.     RETURNS       ... unsigned     - The number of chars transferred.
  2283.  
  2284.  
  2285.  
  2286.     -------------------------------------------------------------------------
  2287.     NAME          ... fputblk
  2288.  
  2289.     DESCRIPTION   ... Function 0x19. Writes a block of data to the port.
  2290.                       Since the FOSSIL's transmit buffer may not have
  2291.                       sufficient room, transmission of the complete block is
  2292.                       never guaranteed.  This call has significantly less
  2293.                       overhead than calling fputch a number of times, and
  2294.                       should be used in preference at least in high speed
  2295.                       situations or at peariods of intense activity (such
  2296.                       as file transfers).
  2297.  
  2298.     PROTOTYPE     ... unsigned int fputblk (unsigned int p, void far *buf,
  2299.                                             unsigned int z);
  2300.  
  2301.     PARAMETERS    ... p            - Port number.
  2302.                       buf          - Buffer to be transfered.
  2303.                       z            - Maximum number of chars to transfer
  2304.                                      from buffer.
  2305.  
  2306.     RETURNS       ... unsigned     - The number of chars transferred.
  2307.  
  2308.  
  2309.  
  2310.     -------------------------------------------------------------------------
  2311.     NAME          ... fbreak
  2312.  
  2313.     DESCRIPTION   ... Function 0x1A. Begin/End sending a break signal.
  2314.                       This function sets  (transmits) or resets the break
  2315.                       signal line in the modems signal.  This signal is
  2316.                       often used for special processing or override
  2317.                       signalling between local and remote systems.
  2318.  
  2319.     PROTOTYPE     ... void fbreak(unsigned int p, unsigned int f);
  2320.  
  2321.     PARAMETERS    ... p            - Port number.
  2322.                       f            - Mode of break signal.
  2323.                                      0x00  - Stop sending break.
  2324.                                      0x01  - Begin sending break.
  2325.  
  2326.     RETURNS       ... void
  2327.  
  2328.  
  2329.     -------------------------------------------------------------------------
  2330.     NAME          ... finfo
  2331.  
  2332.     DESCRIPTION   ... Function 0x1B. Gets information about the fossil
  2333.                       driver.
  2334.  
  2335.     PROTOTYPE     ... unsigned int finfo(unsigned int p, void far *buf,
  2336.                                          unsigned int z);
  2337.  
  2338.     PARAMETERS    ... p            - Port number.
  2339.                       buf          - The user buffer to which the
  2340.                                      information will be transferred to.
  2341.                                      See table below for buffer format.
  2342.  
  2343.                            Format of driver info
  2344.                            ---------------------
  2345.  
  2346.                            Offs    Size   Description
  2347.                            ----    ----   -----------------------
  2348.                            0x00    WORD   size of structure in bytes.
  2349.                            0x02    BYTE   FOSSIL spec conformance.
  2350.                            0x03    BYTE   revision of driver
  2351.                            0x04    DWORD  pointer to ID string.
  2352.                            0x08    WORD   size of input buffer.
  2353.                            0x0A    WORD   bytes left in input buffer.
  2354.                            0x0C    WORD   size of output buffer.
  2355.                            0x0E    WORD   bytes left in output buffer.
  2356.                            0x10    BYTE   width of screen.
  2357.                            0x11    BYTE   length of screen.
  2358.                            0x12    BYTE   computer to modem baud rate.
  2359.  
  2360.                       z            - Size of user buffer.
  2361.  
  2362.     RETURNS       ... unsigned     - The number of chars transferred.
  2363.  
  2364.  
  2365.     -------------------------------------------------------------------------
  2366.     NAME          ... faddapp
  2367.  
  2368.  
  2369.     PROTOTYPE     ... unsigned int faddapp(unsigned int p, unsigned int *c,
  2370.                                            void (far *func)());
  2371.  
  2372.     PARAMETERS    ... p            - Port number.
  2373.                       c            -
  2374.                       func         -
  2375.  
  2376.     RETURNS       ... unsigned     -
  2377.  
  2378.  
  2379.     -------------------------------------------------------------------------
  2380.     NAME          ... fdelapp
  2381.  
  2382.     DESCRIPTION   ... Function 0x1D. Removes a multiplex appendage to the
  2383.                       FOSSIL, this should be used in conjunction with the
  2384.                       faddapp function.
  2385.  
  2386.     PROTOTYPE     ... unsigned int fdelapp(unsigned int p, unsigned int *c,
  2387.                                            void (far *func)());
  2388.  
  2389.     PARAMETERS    ... p            - Port number.
  2390.                       c            -
  2391.                       func         -
  2392.  
  2393.     RETURNS       ... unsigned     -
  2394.  
  2395.  
  2396.  
  2397.  
  2398.  
  2399.  
  2400.     5.  High level functions:
  2401.     -------------------------
  2402.  
  2403.         The high level functions are mainly window functions and internally
  2404.         use the low level functions functions.
  2405.  
  2406.  
  2407.  
  2408.  
  2409.     5.1  Window functions:
  2410.     ----------------------
  2411.  
  2412.  
  2413.     ------------------------------------------------------------------------
  2414.     NAME          ... Wclear
  2415.  
  2416.     DESCRIPTION   ... Clears the contents of a window.
  2417.  
  2418.     PROTOTYPE     ... void Wclear(WINDOW *wnd)
  2419.  
  2420.     ARGUMENTS     ... wnd          - Window handle.
  2421.  
  2422.     RETURNS       ... void
  2423.  
  2424.  
  2425.  
  2426.  
  2427.  
  2428.     ------------------------------------------------------------------------
  2429.     NAME          ... Wcursor
  2430.  
  2431.     DESCRIPTION   ... Sets a windows cursor
  2432.  
  2433.     PROTOTYPE     ... void Wcursor(WINDOW *wnd, int x, int y)
  2434.  
  2435.     ARGUMENTS     ... wnd          - Window handle.
  2436.                       x            - The starting column.
  2437.                       y            - The starting row.
  2438.  
  2439.     RETURNS       ... void
  2440.  
  2441.  
  2442.     ------------------------------------------------------------------------
  2443.     NAME          ... Wdeleteall
  2444.  
  2445.     DESCRIPTION   ... Closes all the windows by recursively calling the
  2446.                       Wdelete function. Use this with caution as it will
  2447.                       every window you have open.
  2448.  
  2449.     PROTOTYPE     ... void Wdeletall(void)
  2450.  
  2451.     ARGUMENTS     ... void
  2452.  
  2453.     RETURNS       ... void
  2454.  
  2455.  
  2456.     ------------------------------------------------------------------------
  2457.     NAME          ... Wdelete
  2458.  
  2459.     DESCRIPTION   ... Deletes a window and frees all the memory that it
  2460.                       initially allocated.
  2461.  
  2462.     PROTOTYPE     ... void Wdelete(WINDOW *wnd)
  2463.  
  2464.     ARGUMENTS     ... wnd          - Window handle.
  2465.  
  2466.     RETURNS       ... void
  2467.  
  2468.  
  2469.  
  2470.  
  2471.     -------------------------------------------------------------------------
  2472.     NAME          ... Westablish
  2473.  
  2474.     DESCRIPTION   ... Creats a new window.
  2475.  
  2476.     PROTOTYPE     ... WINDOW *Westablish (x int, y int, h int, w int)
  2477.  
  2478.     PARAMETERS    ... x            - The starting column of the window.
  2479.                       y            - The starting row of the box.
  2480.                       h            - The height of the window.
  2481.                       w            - The width of the window.
  2482.  
  2483.     RETURNS       ... A pointer to the new created window. It will return
  2484.                       NULL if memory allocation fails.
  2485.  
  2486.  
  2487.  
  2488.  
  2489.     ------------------------------------------------------------------------
  2490.     NAME          ... Wforefront
  2491.  
  2492.     DESCRIPTION   ... This will re position the window so that it is in
  2493.                       front of all the other windows.
  2494.  
  2495.     PROTOTYPE     ... #define Wforefront(wnd)
  2496.  
  2497.     ARGUMENTS     ... wnd          - The window handle.
  2498.  
  2499.  
  2500.  
  2501.     ------------------------------------------------------------------------
  2502.     NAME          ... Wgetsel
  2503.  
  2504.     DESCRIPTION   ... Allows the user to make a window selection.
  2505.  
  2506.     PROTOTYPE     ... int Wgetsel(WINDOW *wnd, int s, char *keys)
  2507.  
  2508.     ARGUMENTS     ... wnd          - Window handle.
  2509.                       s            - Selection.
  2510.                       keys         - A pointer to a string whoose charcaters
  2511.                                      are valid keystrokes
  2512.  
  2513.     RETURNS       ... The key pressed.
  2514.  
  2515.  
  2516.  
  2517.  
  2518.     ------------------------------------------------------------------------
  2519.     NAME          ... Whide
  2520.  
  2521.     DESCRIPTION   ... Hides a window, this only makes it invisible so it
  2522.                       can be restored.
  2523.  
  2524.     PROTOTYPE     ... void Whide(WINDOW *wnd)
  2525.  
  2526.     ARGUMENTS     ... wnd          - Window handle.
  2527.  
  2528.     RETURNS       ... void
  2529.  
  2530.  
  2531.  
  2532.  
  2533.     ------------------------------------------------------------------------
  2534.     NAME          ... Wmove
  2535.  
  2536.     DESCRIPTION   ... Moves a window and its contents.
  2537.  
  2538.     PROTOTYPE     ... #define Wmove(wnd,x,y)
  2539.  
  2540.     ARGUMENTS     ... wnd          - Window handle.
  2541.                       x            - The starting column.
  2542.                       y            - The starting row.
  2543.  
  2544.  
  2545.  
  2546.     ------------------------------------------------------------------------
  2547.     NAME          ... Wprintf
  2548.  
  2549.     DESCRIPTION   ... Writes a formatted variable argument to a window,
  2550.                       as with the printf function.
  2551.  
  2552.     PROTOTYPE     ... void Wprintf(WINDOW *wnd, char *ln, ...)
  2553.  
  2554.     ARGUMENTS     ... wnd          - Window handle.
  2555.                       ln           - The formatted line to write.
  2556.  
  2557.     RETURNS       ... void
  2558.  
  2559.  
  2560.  
  2561.  
  2562.     ------------------------------------------------------------------------
  2563.     NAME          ... Wprompt
  2564.  
  2565.     DESCRIPTION   ... Display a window prompt.
  2566.  
  2567.     PROTOTYPE     ... void Wprompt(WINDOW *wnd, int x, int y, char *s)
  2568.  
  2569.     ARGUMENTS     ... wnd          - Window handle.
  2570.                       x            - The starting column.
  2571.                       y            - The starting row.
  2572.                       s            - The prompt string.
  2573.  
  2574.     RETURNS       ... void
  2575.  
  2576.  
  2577.     ------------------------------------------------------------------------
  2578.     NAME          ... Wputch
  2579.  
  2580.     DESCRIPTION   ... Outputs a character to a window, using the WIN_FACE
  2581.                       attributes.
  2582.  
  2583.     PROTOTYPE     ... void Wputch(WINDOW *wnd, int c)
  2584.  
  2585.     ARGUMENTS     ... wnd          - Window handle.
  2586.                       c            - The character to write.
  2587.  
  2588.     RETURNS       ... void
  2589.  
  2590.  
  2591.  
  2592.     ------------------------------------------------------------------------
  2593.     NAME          ... Wputchat
  2594.  
  2595.     DESCRIPTION   ... Outputs a character and attribute to a window.
  2596.  
  2597.     PROTOTYPE     ... void Wputchar(WINDOW *wnd, int c, int bg, int fg,
  2598.                                     int i)
  2599.  
  2600.     ARGUMENTS     ... wnd          - Window handle.
  2601.                       c            - The character to write.
  2602.                       bg           - Background colour.
  2603.                       fg           - Foreground colour.
  2604.                       i            - Intensity (BRIGHT || DIM).
  2605.  
  2606.     RETURNS       ... void
  2607.  
  2608.  
  2609.  
  2610.     ------------------------------------------------------------------------
  2611.     NAME          ... Wrear
  2612.  
  2613.     DESCRIPTION   ... This will reposition a window so that it is the
  2614.                       very last window on the screen.
  2615.  
  2616.     PROTOTYPE     ... #define Wrear(wnd)
  2617.  
  2618.     ARGUMENTS     ... wnd          - Window handle.
  2619.  
  2620.  
  2621.  
  2622.  
  2623.     ------------------------------------------------------------------------
  2624.     NAME          ... Wresetvideo
  2625.  
  2626.     DESCRIPTION   ... Normalises the video attributes for a given window.
  2627.                       This would set the attributes to the default state.
  2628.  
  2629.     PROTOTYPE     ... #define Wresetvideo(wnd)
  2630.  
  2631.     ARGUMENTS     ... wnd          - Window handle.
  2632.  
  2633.  
  2634.  
  2635.     ------------------------------------------------------------------------
  2636.     NAME          ... Wrevvideo
  2637.  
  2638.     DESCRIPTION   ... Reverses the video attributes for a given window.
  2639.  
  2640.     PROTOTYPE     ... #define Wrevvideo(wnd)
  2641.  
  2642.     ARGUMENTS     ... wnd          - Window handle.
  2643.  
  2644.  
  2645.  
  2646.     ------------------------------------------------------------------------
  2647.     NAME          ... Wrmove
  2648.  
  2649.     DESCRIPTION   ... Moves a window and its contents, this is different to
  2650.                       the Wmove macro in that it will move a window and
  2651.                       remember which other windows are behind or in front of
  2652.                       it. It will move behind if it is not the active window.
  2653.  
  2654.     PROTOTYPE     ... #define Wrmove(wnd,x,y)
  2655.  
  2656.     ARGUMENTS     ... wnd          - Window handle.
  2657.                       x            - The starting column.
  2658.                       y            - The starting row.
  2659.  
  2660.  
  2661.  
  2662.  
  2663.     -------------------------------------------------------------------------
  2664.     NAME          ... Wsetborder
  2665.  
  2666.     DESCRIPTION   ... Sets a windows border to particular format.
  2667.  
  2668.     PROTOTYPE     ... void Wsetborder(WINDOW *wnd, int btype)
  2669.  
  2670.     ARGUMENTS     ... wnd          - Window handle.
  2671.                       btype        - Sets the border styles,
  2672.  
  2673.                                      BRD_SPACE      - spaces                                       /* single line */
  2674.                                      BRD_SINGLE     - single line
  2675.                                      BRD_DOUBLE     - double line
  2676.                                      BRD_DOUBLESIDE - double sides & sngl top
  2677.                                      BRD_DOUBLETOP  - double top & sngl sides
  2678.                                      BRD_SINGLESIDE - ditto
  2679.                                      BRD_SINGLETOP  - ditto
  2680.                                      BRD_NOBORDER   - no borders
  2681.  
  2682.     RETURNS       ... void
  2683.  
  2684.  
  2685.  
  2686.  
  2687.     -------------------------------------------------------------------------
  2688.     NAME          ... Wsetcolour
  2689.  
  2690.     DESCRIPTION   ... Sets up the colors for a given window. If the video
  2691.                       adaptor is monochrome then the function uses its
  2692.                       default attributes (BLACK and WHITE) and returns.
  2693.                       You may also use the predifined constant BLINK to
  2694.                       add blinking attribute to any of the colours.
  2695.                       Eg   RED+BLINK.
  2696.  
  2697.     PROTOTYPE     ... void Wsetcolour (WINDOW *wnd, int area,
  2698.                                        int bg, int fg, int inten);
  2699.  
  2700.     PARAMETERS    ... wnd          - Pointer to the slected window.
  2701.                       area         - The area to repaint.
  2702.  
  2703.                                      WIN_BORDER  - border or frame
  2704.                                      WIN_TITLE   - title area
  2705.                                      WIN_ACCENT  - accent, highlight bar
  2706.                                      WIN_FACE    - window face
  2707.                                      WIN_FLDFACE - window field face
  2708.                                      WIN_ALL     - all above components
  2709.  
  2710.                       bg           - Back ground attribute.
  2711.                       fg           - Fore ground attribute.
  2712.                       inten        - Intensity.
  2713.                                      BRIGHT      - high intensity
  2714.                                      DIM         - low intensity
  2715.  
  2716.     RETURNS       ... void
  2717.  
  2718.  
  2719.  
  2720.  
  2721.     ------------------------------------------------------------------------
  2722.     NAME          ... Wsetintensity
  2723.  
  2724.     DESCRIPTION   ... Sets the intensity of a given window.
  2725.  
  2726.     PROTOTYPE     ... void Wsetintensity(WINDOW *wnd, int inten)
  2727.  
  2728.     ARGUMENTS     ... wnd          - Window handle.
  2729.                       inten        - The intensity to set to.
  2730.                                      BRIGHT      - high intensity
  2731.                                      DIM         - low intensity
  2732.  
  2733.     RETURNS       ... void
  2734.  
  2735.  
  2736.  
  2737.  
  2738.     ------------------------------------------------------------------------
  2739.     NAME          ... Wsettitle
  2740.  
  2741.     DESCRIPTION   ... Sets the title of a window.
  2742.  
  2743.     PROTOTYPE     ... void Wsettitle(WINDOW *wnd, char *title, int just)
  2744.  
  2745.     ARGUMENTS     ... wnd          - Window handle.
  2746.                       title        - Pointer to the string containing the
  2747.                                      title.
  2748.                       just         - The justification of the title.
  2749.                                      JUST_C     - centre justify
  2750.                                      JUST_L     - left justify
  2751.                                      JUST_R     - right justify
  2752.  
  2753.     RETURNS       ... void
  2754.  
  2755.  
  2756.  
  2757.  
  2758.     ------------------------------------------------------------------------
  2759.     NAME          ... Wshow
  2760.  
  2761.     DESCRIPTION   ... Displays a window. The window must have already been
  2762.                       established using Westablish.
  2763.  
  2764.     PROTOTYPE     ... void Wshow(WINDOW *wnd)
  2765.  
  2766.     ARGUMENTS     ... wnd          - Window handle.
  2767.  
  2768.     RETURNS       ... void
  2769.  
  2770.  
  2771.  
  2772.  
  2773.  
  2774.  
  2775.  
  2776.  
  2777.     5.2  Menu functions:
  2778.     --------------------
  2779.  
  2780.  
  2781.  
  2782.     -------------------------------------------------------------------------
  2783.     NAME          ... Minit
  2784.  
  2785.     DESCRIPTION   ... This function sets all the configuration variables in
  2786.                       a pulldown menu to the default state. The colours are
  2787.                       all set to monochrome (BLACK and WHITE) , the title
  2788.                       string is NULL and the border is BRD_SINGLE. The
  2789.                       functions  Msetborder(), Msettitle() and Msetcolour()
  2790.                       can be  called to change the style.
  2791.  
  2792.     PROTOTYPE     ... void Minit (void);
  2793.  
  2794.     PARAMETERS    ... void
  2795.  
  2796.     RETURNS       ... void
  2797.  
  2798.  
  2799.     ------------------------------------------------------------------------
  2800.     NAME          ... Mselect
  2801.  
  2802.     DESCRIPTION   ... Opens and executes a pull-down type menu.
  2803.                       See the SSTWIN.H file for structure components.
  2804.  
  2805.     PROTOTYPE     ... void Mselect(MENU *mn, int h)
  2806.  
  2807.     ARGUMENTS     ... mn           - Pointer to the menu structure.
  2808.                       h            - If menu should hide prior to calling
  2809.                                      selected function.
  2810.                                      TRUE   - Hide
  2811.                                      FALSE  - Leave as is
  2812.     RETURNS       ... void
  2813.  
  2814.  
  2815.  
  2816.     -------------------------------------------------------------------------
  2817.     NAME          ... Msetborder
  2818.  
  2819.     DESCRIPTION   ... Sets up the border style for the current pull-down
  2820.                       menu.
  2821.  
  2822.     PROTOTYPE     ... void Msetborder (int btype);
  2823.  
  2824.     PARAMETERS    ... btype        - The border style.
  2825.                                      BRD_SPACE      - spaces                                       /* single line */
  2826.                                      BRD_SINGLE     - single line
  2827.                                      BRD_DOUBLE     - double line
  2828.                                      BRD_DOUBLESIDE - double sides & sngl top
  2829.                                      BRD_DOUBLETOP  - double top & sngl sides
  2830.                                      BRD_SINGLESIDE - ditto
  2831.                                      BRD_SINGLETOP  - ditto
  2832.                                      BRD_NOBORDER   - no borders
  2833.  
  2834.     RETURNS       ... void
  2835.  
  2836.  
  2837.  
  2838.     -------------------------------------------------------------------------
  2839.     NAME          ... Msetcolour
  2840.  
  2841.     DESCRIPTION   ... Sets up the colors for the current pull-down menu.
  2842.                       If the adaptor is monochrome then the function uses
  2843.                       its default attributes (BLACK and WHITE) and ignore
  2844.                       the parameters you have passed.
  2845.  
  2846.     PROTOTYPE     ... void Msetcolour (int area, int bg, int fg,
  2847.                                        int inten);
  2848.  
  2849.                       area         - The area to repaint.
  2850.  
  2851.                                      WIN_BORDER  - border or frame
  2852.                                      WIN_TITLE   - title area
  2853.                                      WIN_ACCENT  - accent, highlight bar
  2854.                                      WIN_FACE    - window face
  2855.                                      WIN_FLDFACE - window field face
  2856.                                      WIN_ALL     - all above components
  2857.  
  2858.                       bg           - Back ground attribute.
  2859.                       fg           - Fore ground attribute.
  2860.                       inten        - Intensity.
  2861.                                      BRIGHT      - high intensity
  2862.                                      DIM         - low intensity
  2863.  
  2864.     RETURNS       ... void
  2865.  
  2866.  
  2867.  
  2868.     -------------------------------------------------------------------------
  2869.     NAME          ... Msetfullwidth
  2870.  
  2871.     DESCRIPTION   ... Forces the pull-down menu to use the entire width of
  2872.                       the screen, or a calculated minimum width.
  2873.  
  2874.     PROTOTYPE     ... void Msetfullwidth(int f);
  2875.  
  2876.     PARAMETERS    ... f            -  FALSE   - Use calculated screen width
  2877.                                       TRUE    - Use full screen width.
  2878.  
  2879.     RETURNS       ... void
  2880.  
  2881.  
  2882.  
  2883.     ------------------------------------------------------------------------
  2884.     NAME          ... Msettitle
  2885.  
  2886.     DESCRIPTION   ... Sets the title for the current pull-down menu.
  2887.  
  2888.     PROTOTYPE     ... void Msettitle (char *title, int just);
  2889.  
  2890.     ARGUMENTS     ... title        - Pointer to the string containing the
  2891.                                      title.
  2892.                       just         - The justification of the title.
  2893.                                      JUST_C     - centre justify
  2894.                                      JUST_L     - left justify
  2895.                                      JUST_R     - right justify
  2896.  
  2897.     RETURNS       ... void
  2898.  
  2899.  
  2900.  
  2901.  
  2902.  
  2903.  
  2904.     5.3  Data entry functions:
  2905.     --------------------------
  2906.  
  2907.  
  2908.  
  2909.     ------------------------------------------------------------------------
  2910.     NAME          ... Fcleartemplate
  2911.  
  2912.     DESCRIPTION   ... Clears a template to all blanks, see also
  2913.                       Fnulltemplate.
  2914.  
  2915.     PROTOTYPE     ... void Fcleartemplate(WINDOW *wnd)
  2916.  
  2917.     ARGUMENTS     ... wnd          - Window handle.
  2918.  
  2919.     RETURNS       ... void
  2920.  
  2921.  
  2922.  
  2923.     ------------------------------------------------------------------------
  2924.     NAME          ... Fdataentry
  2925.  
  2926.     DESCRIPTION   ... Process data entry for a screen template.
  2927.  
  2928.     PROTOTYPE     ... int Fdataentry(WINDOW *wnd, int p)
  2929.  
  2930.     ARGUMENTS     ... wnd          - Window handle.
  2931.                       p            - TRUE  - process all keystrokes. Ret
  2932.                                              PgUp, PgDown, Home , End etc.
  2933.                                      FASLE - preserve PgUp, PgDown, Home,
  2934.                                              End for internal use.
  2935.  
  2936.     RETURNS       ... The last keyboard keystroke.
  2937.  
  2938.  
  2939.     ------------------------------------------------------------------------
  2940.     NAME          ... Fdataview
  2941.  
  2942.     DESCRIPTION   ... Displays the data entry for a screen template.
  2943.                       This will not allow any editing and the cursor is
  2944.                       invisible inside this function.
  2945.  
  2946.     PROTOTYPE     ... int Fdataview(WINDOW *wnd)
  2947.  
  2948.     ARGUMENTS     ... wnd          - Window handle.
  2949.  
  2950.     RETURNS       ... The last keyboard keystroke.
  2951.  
  2952.  
  2953.     ------------------------------------------------------------------------
  2954.     NAME          ... Fendfunc
  2955.  
  2956.     DESCRIPTION   ... This is a powerfull feature in field editing. This
  2957.                       function will allow you to specify a new function
  2958.                       that will determine which keys are valid for exiting
  2959.                       field edit sessions. The function must be set prior
  2960.                       to the Fdataentry function. For a sample take a look
  2961.                       at the default_endstroke function in sstfield.c .
  2962.  
  2963.     PROTOTYPE     ... void  Fendfunc(int (*func) (int));
  2964.  
  2965.     ARGUMENTS     ... func         - Pointer to the new function to be
  2966.                                      used. If NULL it will use the
  2967.                                      default function.
  2968.  
  2969.     RETURNS       ... void
  2970.  
  2971.  
  2972.     ------------------------------------------------------------------------
  2973.     NAME          ... Ferrorfunc
  2974.  
  2975.     DESCRIPTION   ... This is a powerfull feature in field editing. During
  2976.                       each keypress inside a field, the char entered is
  2977.                       checked for validation. If the key pressed is invalid
  2978.                       then the function specified is called. There are
  2979.                       certain rules that should be followed. During each
  2980.                       invalid key pressed a string of the error
  2981.                       interpreation is passed to the function. For each
  2982.                       corrective action and valid keystroke a NULL is
  2983.                       passed to the function. Upon initialisation a built
  2984.                       in function is used that pops a small window to alert
  2985.                       the user, and the windows disappears during the
  2986.                       corrective action.
  2987.  
  2988.  
  2989.     PROTOTYPE     ... void  Ferrorfunc(int (*func) (char *s));
  2990.  
  2991.     ARGUMENTS     ... func         - Pointer to the new function to be
  2992.                                      used. If NULL it will use the
  2993.                                      default function.
  2994.                       s            - The string interpreation for the
  2995.                                      error created.
  2996.  
  2997.     RETURNS       ... void
  2998.  
  2999.  
  3000.  
  3001.     ------------------------------------------------------------------------
  3002.     NAME          ... Festablish
  3003.  
  3004.     DESCRIPTION   ... Establishes a field in a window template. This
  3005.                       function is used in making a window a field template.
  3006.                       You need to pass it parameters for its location,
  3007.                       the field mask, the edit buffer, and the field types
  3008.                       etc.  The display mask is a string enclosed in double
  3009.                       quotes and is used in defining an input field for the
  3010.                       particular data element. The underscore character
  3011.                       represents character positions in the mask.
  3012.                       Punctuation characters may be inserted anywhere in the
  3013.                       mask string. The number of underscore characters must
  3014.                       be atleast the length of the data element, but may be
  3015.                       more.
  3016.  
  3017.     PROTOTYPE     ... FIELD *Festablish(WINDOW *wnd, int cl, int rw,
  3018.                                         char *msk, char *bf, int ty,
  3019.                                         int fcnv)
  3020.  
  3021.     ARGUMENTS     ... wnd          - Window handle.
  3022.                       cl           - The starting column of the field.
  3023.                       rw           - The starting row of the field.
  3024.                       msk          - The field input mask string. eg
  3025.  
  3026.                                      "__/__/__"       - sample date mask.
  3027.                                      "(___)____-__"   - sample phone with
  3028.                                                         area code mask.
  3029.                                      "$___.__"        - sample currency mask.
  3030.  
  3031.                       bf           - The buffer that is updated upon
  3032.                                      editing.
  3033.                       ty           - The field type,
  3034.                                      FLD_ALNUM    - alpha & numeric &
  3035.                                                     space
  3036.                                      FLD_ALPHA    - alpha & space
  3037.                                      FLD_DIGIT    - digit only
  3038.                                      FLD_ASCII    - ascii char only
  3039.                                      FLD_PRINT    - printable character
  3040.                                      FLD_XDIGIT   - hexadecimal char
  3041.                                      FLD_DATE     - date fromat char
  3042.                                      FLD_INT      - integer
  3043.                                      FLD_CURR     - currency format
  3044.  
  3045.                       fcnv         - The field conversion flags.
  3046.  
  3047.                                      FLD_LJUST    - left justify field
  3048.                                      FLD_RJUST    - right justify field
  3049.                                      FLD_TOUPPER  - convert to upper case
  3050.                                      FLD_TOLOWER  - convert to lower case
  3051.                                      FLD_TOPROPER - convert to Proper case
  3052.                                      FLD_ZFILL    - zero fill blanks
  3053.  
  3054.  
  3055.     RETURNS       ... Pointer to the new created field. The function may
  3056.                       also return NULL if no memory could be allocated to
  3057.                       the field.
  3058.  
  3059.  
  3060.  
  3061.     ------------------------------------------------------------------------
  3062.     NAME          ... Finittemplate
  3063.  
  3064.     DESCRIPTION   ... Initialises all the variables needed to create an
  3065.                       entry template. The window must have already been
  3066.                       established to call this function. This function
  3067.                       also frees any memory used by the fields, so may
  3068.                       be called after the editing session prior to
  3069.                       deleting the window.
  3070.  
  3071.     PROTOTYPE     ... void Finittemplate(WINDOW *wnd);
  3072.  
  3073.     ARGUMENTS     ... wnd          - Window handle;
  3074.  
  3075.     RETURNS       ... void
  3076.  
  3077.  
  3078.  
  3079.     ------------------------------------------------------------------------
  3080.     NAME          ... Fnulltemplate
  3081.  
  3082.     DESCRIPTION   ... Clears a template to all NULL chars, see also
  3083.                       Fcleartemplate.
  3084.  
  3085.     PROTOTYPE     ... void Fnulltemplate(WINDOW *wnd)
  3086.  
  3087.     ARGUMENTS     ... wnd          - Window handle.
  3088.  
  3089.     RETURNS       ... void
  3090.  
  3091.  
  3092.  
  3093.     ------------------------------------------------------------------------
  3094.     NAME          ... Fprevalidate
  3095.  
  3096.     DESCRIPTION   ... Assigns a validation function to a particular field.
  3097.                       The function would be called upon each keypress while
  3098.                       still editing a field. This is usefull in converting
  3099.                       or translating each key that is pressed.
  3100.  
  3101.     PROTOTYPE     ... #define Fprevalidate(f,v) f->fvalid=v
  3102.  
  3103.     ARGUMENTS     ... f            - Pointer to the field structure.
  3104.                   ... v            - Pointer to the function to be used for
  3105.                                      validation.
  3106.  
  3107.  
  3108.  
  3109.     ------------------------------------------------------------------------
  3110.     NAME          ... Fprotect
  3111.  
  3112.     DESCRIPTION   ... Protects a field by not allowing the user to edit
  3113.                       it. It is still displayed etc, but is skipped.
  3114.  
  3115.     PROTOTYPE     ... #define Fprotect(f,s)  f->fprot=s
  3116.  
  3117.     ARGUMENTS     ... f            - Pointer to the field.
  3118.                       s            - TRUE  - Protect.
  3119.                                      FALSE - Unprotect.
  3120.  
  3121.  
  3122.  
  3123.  
  3124.     ------------------------------------------------------------------------
  3125.     NAME          ... Fpostvalidate
  3126.  
  3127.     DESCRIPTION   ... Assigns a validation function to a particular field.
  3128.                       The function would be called when the editing of the
  3129.                       field is completed.
  3130.  
  3131.     PROTOTYPE     ... #define Fpostvalidate(f,v) f->fvalid=v
  3132.  
  3133.     ARGUMENTS     ... f            - Pointer to the field structure.
  3134.                   ... v            - Pointer to the function to be used for
  3135.                                      validation.
  3136.  
  3137.  
  3138.  
  3139.     ------------------------------------------------------------------------
  3140.     NAME          ... Fhelpfunc
  3141.  
  3142.     DESCRIPTION   ... Assigns a new help function to the specified field.
  3143.                       A help function may be diplayed for the particular
  3144.                       field upon pressing the help key (usually F1) or
  3145.                       instantly as soon as the field is selected,
  3146.                       see the argument "w" for more details.
  3147.  
  3148.  
  3149.     PROTOTYPE     ... void Fhelpfunc(FIELD *f, void (*h)(char *), int w);
  3150.  
  3151.     ARGUMENTS     ... f            - Pointer to the field.
  3152.                       h            - Pointer to the help function.
  3153.                       w            - Field help type.
  3154.                                      HELP_KEYED   - when help key pressed
  3155.                                      HELP_INITIAL - when initially on field
  3156.                                      HELP_ALWAYS  - when always on field
  3157.                                      HELP_DONE    - set as completed help
  3158.  
  3159.  
  3160.  
  3161.     ------------------------------------------------------------------------
  3162.     NAME          ... Fsethelpwin
  3163.  
  3164.     DESCRIPTION   ... Set a field's help window.
  3165.  
  3166.     PROTOTYPE     ... void Fsethelpwin(FIELD *fld, char *hwin, int x, int y)
  3167.  
  3168.     ARGUMENTS     ... fld          - Pointer to the field structure.
  3169.                       hwin         - Help tag string.
  3170.                       x            - The starting column.
  3171.                       y            - The starting row.
  3172.  
  3173.     RETURNS       ... void
  3174.  
  3175.  
  3176.  
  3177.  
  3178.     ------------------------------------------------------------------------
  3179.     NAME          ... Ftally
  3180.  
  3181.     DESCRIPTION   ... Displays all the fields in a window.
  3182.  
  3183.     PROTOTYPE     ... void Ftally(WINDOW *wnd)
  3184.  
  3185.     ARGUMENTS     ... wnd          - Window handle.
  3186.  
  3187.     RETURNS       ... void
  3188.  
  3189.  
  3190.  
  3191.  
  3192.  
  3193.  
  3194.  
  3195.  
  3196.     5.4  Editor functions:
  3197.     ----------------------
  3198.  
  3199.  
  3200.     ------------------------------------------------------------------------
  3201.     NAME          ... Eopen
  3202.  
  3203.     DESCRIPTION   ... Opens a text editing window. The window must first be
  3204.                       created using the Westablish function, and its
  3205.                       characteristics may be set eg (title and colours).
  3206.                       The window is to be displayed using the Wshow
  3207.                       function then you can call the Eopen function.
  3208.                       See sec 2.4 for the editing commands.
  3209.  
  3210.     PROTOTYPE     ... void Eopen(WINDOW *wnd, char *bf, int bsize)
  3211.  
  3212.     ARGUMENTS     ... wnd          - Window handle.
  3213.                       bf           - Pointer to the text buffer.
  3214.                       bsize        - The size of the text buffer.
  3215.  
  3216.     RETURNS       ... void
  3217.  
  3218.  
  3219.  
  3220.  
  3221.  
  3222.     5.5  Help system functions:
  3223.     ---------------------------
  3224.  
  3225.  
  3226.  
  3227.     ------------------------------------------------------------------------
  3228.     NAME          ... Hload
  3229.  
  3230.     DESCRIPTION   ... Loads a help definition file. If the help file is
  3231.                       unable to be opened for some reason the function
  3232.                       returns.
  3233.  
  3234.     PROTOTYPE     ... void Hload(char *hn)
  3235.  
  3236.     ARGUMENTS     ... hn           - The name of the help file including
  3237.                                      full path.
  3238.  
  3239.     RETURNS       ... void
  3240.  
  3241.  
  3242.     ------------------------------------------------------------------------
  3243.     NAME          ... Hset
  3244.  
  3245.     DESCRIPTION   ... Sets a particular help screen to be current and
  3246.                       active.
  3247.  
  3248.     PROTOTYPE     ... void Hset(char *s, int x, int y)
  3249.  
  3250.     ARGUMENTS     ... s            - The help title tag.
  3251.                       x            - Starting column of the help screen.
  3252.                       y            - Starting row of the help screen.
  3253.  
  3254.     RETURNS       ... void
  3255.  
  3256.  
  3257.  
  3258.     -------------------------------------------------------------------------
  3259.     NAME          ... Hsetborder
  3260.  
  3261.     DESCRIPTION   ... Sets a help windows border to a particular format.
  3262.  
  3263.     PROTOTYPE     ... void Hsetborder(int btype)
  3264.  
  3265.     ARGUMENTS     ... btype        - Sets the border styles
  3266.                                      BRD_SPACE      - spaces                                       /* single line */
  3267.                                      BRD_SINGLE     - single line
  3268.                                      BRD_DOUBLE     - double line
  3269.                                      BRD_DOUBLESIDE - double sides & sngl top
  3270.                                      BRD_DOUBLETOP  - double top & sngl sides
  3271.                                      BRD_SINGLESIDE - ditto
  3272.                                      BRD_SINGLETOP  - ditto
  3273.                                      BRD_NOBORDER   - no borders
  3274.  
  3275.     RETURNS       ... void
  3276.  
  3277.  
  3278.  
  3279.  
  3280.  
  3281.     -------------------------------------------------------------------------
  3282.     NAME          ... Hsetcolour
  3283.  
  3284.     DESCRIPTION   ... Sets up the colors for a help window.
  3285.  
  3286.     PROTOTYPE     ... void Hsetcolour (int area, int bg, int fg, int inten);
  3287.  
  3288.     PARAMETERS    ... area         - The area to repaint.
  3289.  
  3290.                                      WIN_BORDER  - border or frame
  3291.                                      WIN_TITLE   - title area
  3292.                                      WIN_ACCENT  - accent, highlight bar
  3293.                                      WIN_FACE    - window face
  3294.                                      WIN_FLDFACE - window field face
  3295.                                      WIN_ALL     - all above components
  3296.  
  3297.                       bg           - Back ground attribute.
  3298.                       fg           - Fore ground attribute.
  3299.                       inten        - Intensity.
  3300.                                      BRIGHT      - high intensity
  3301.                                      DIM         - low intensity
  3302.     RETURNS       ... void
  3303.  
  3304.  
  3305.  
  3306.     -------------------------------------------------------------------------
  3307.     NAME          ... Msetspace
  3308.  
  3309.     DESCRIPTION   ... Sets the spacing between items on the menu. This is
  3310.                       usefull in streching out the menu to fit into a screen
  3311.                       when there isnt enough items etc. The spacing area
  3312.                       parameter is bitwise so you may pass
  3313.                       SPC_LEFT | SPC_RIGHT etc.
  3314.  
  3315.     PROTOTYPE     ... void Msetspace(int sp, int a)
  3316.  
  3317.     PARAMETERS    ... sp           - The number of space chars to use for
  3318.                                      spacing.
  3319.                       a            - The portion of the menu that will be
  3320.                                      used for spacing.
  3321.  
  3322.                                      SPC_BETWEEN  - spacing between items
  3323.                                      SPC_LEFT     - left most end of menu
  3324.                                      SPC_RIGHT    - right most end of menu
  3325.  
  3326.     RETURNS       ... void
  3327.  
  3328.  
  3329.     ------------------------------------------------------------------------
  3330.     NAME          ... Hsettitle
  3331.  
  3332.     DESCRIPTION   ... Sets the title of a help window.
  3333.  
  3334.     PROTOTYPE     ... void Hsettitle(char *t, int j)
  3335.  
  3336.     ARGUMENTS     ... t            - Pointer to the string containing the
  3337.                                      title.
  3338.                       j            - The justification of the title.
  3339.                                      JUST_C     - centre justify
  3340.                                      JUST_L     - left justify
  3341.                                      JUST_R     - right justify
  3342.  
  3343.     RETURNS       ... void
  3344.  
  3345.  
  3346.  
  3347.  
  3348.  
  3349.     5.6  Selection system functions:
  3350.     --------------------------------
  3351.  
  3352.  
  3353.  
  3354.     ------------------------------------------------------------------------
  3355.     NAME          ... Sdelete
  3356.  
  3357.     DESCRIPTION   ... This function frees all the memory used by the linked
  3358.                       list in the selection system. Call this when the
  3359.                       selection has been made.
  3360.  
  3361.     PROTOTYPE     ... void Sdelete(void)
  3362.  
  3363.     ARGUMENTS     ... void
  3364.  
  3365.     RETURNS       ... void
  3366.  
  3367.  
  3368.     ------------------------------------------------------------------------
  3369.     NAME          ... Sforeach
  3370.  
  3371.     DESCRIPTION   ... Calls a specific function for each of the tagged
  3372.                       selection list elements.
  3373.  
  3374.     PROTOTYPE     ... void Sforeach(void (*func) (char *s));
  3375.  
  3376.     ARGUMENTS     ... func         - Pointer to the function to be called.
  3377.  
  3378.     RETURNS       ... void
  3379.  
  3380.  
  3381.  
  3382.  
  3383.     -------------------------------------------------------------------------
  3384.     NAME          ... Sinsert
  3385.  
  3386.     DESCRIPTION   ... Inserts a string into the selection record. This is
  3387.                       used in establishing a linked list fro the selection
  3388.                       system.
  3389.  
  3390.     PROTOTYPE     ... SelREC *Sinsert(char *s);
  3391.  
  3392.     ARGUMENTS     ... s            - Pointer to string to be inserted.
  3393.  
  3394.     RETURNS       ... Pointer to the selection record.
  3395.  
  3396.  
  3397.  
  3398.  
  3399.     -------------------------------------------------------------------------
  3400.     NAME          ... Sselonestr
  3401.  
  3402.     DESCRIPTION   ... Opens the selection system and prompts the user for
  3403.                       a selection of one item only, ie no tagging.
  3404.  
  3405.     PROTOTYPE     ... char *Sselonestr(int x, int y, int t);
  3406.  
  3407.     ARGUMENTS     ... x            - The starting column.
  3408.                       y            - The starting row.
  3409.                       t            - The number of rows to show in the
  3410.                                      window.
  3411.  
  3412.     RETURNS       ... Pointer to the selection item in the record or NULL
  3413.                       if ESC was pressed.
  3414.  
  3415.  
  3416.  
  3417.     -------------------------------------------------------------------------
  3418.     NAME          ... Sselstr
  3419.  
  3420.     DESCRIPTION   ... Opens the selection system and prompts the user for
  3421.                       a selection of multiple items, ie tagging by using
  3422.                       the space key.
  3423.  
  3424.     PROTOTYPE     ... int Sselstr(int x, int y, int t);
  3425.  
  3426.     ARGUMENTS     ... x            - The starting column.
  3427.                       y            - The starting row.
  3428.                       t            - The number of rows to show in the
  3429.                                      window.
  3430.  
  3431.     RETURNS       ... The last key pressed.
  3432.                       The function Sforeach should be called in extracting
  3433.                       the selected items.
  3434.  
  3435.  
  3436.  
  3437.  
  3438.